div
with width
CSS set to 300px
,4000px
and place them in div
s which support only 300px
@media
CSS media queries to customize which image file to transmit over the network for that specfic client display
imigx
or something similiarhead
element) and load JS files as late as possible (end of body
element)
script
tags for analytics like Google analytics should be placed in the head
elementuse media attributes for links to CSS in HTML files
less specificity in CSS is better
style
block CSS in head
> CSS file outside HTML file (slowest)<script async>
however, while the JS is being executed, HTML parsing is blocked
async
in script tag<script defer>
defer
tagdo not use async
or defer
for page’s critical script tags!