html sizes

·

1 min read

px,%,vw,vh,em,rem

px

px to fixed hota hay ay depend karta hay screen to screen

jasey uhd 4k ,8k may kya hota hay ek high dpi hota hay

manlo ek box chota sa 5cm ka usmay bohot jyada px hogay

aur koi baba ajam kay jamany ki screen hay to usmay 5 cm kay box may bohot kam px hogay

we try to avoid px in our website

%

percentage jo hay screen kay hisab say increase aur decrease hota hay

vw and vh

viewport width and viewport height ay screen say value leta hay 10vw means 10 percentage of width if we decrease or increase screen size it will change

em

em jo hay parent element ki font size leta hay

jesay koi parent element ki font size 16 px hay to child element ki size bhi 16 px hogi

agar child element ki size change karna ho to font size ko change karna padega fir

rem

root elment pay jo laga hay root empherial unit

html may html jo root element hota hay uskay under hi sab kuch aata hay

yani ki ay hamesah root element say hi size lega it is like fixed size

parene ki size kuch bhi ho doesn't matter