Front end performance optimization

Time:2020-2-18

Image optimization

  • Request optimization

    ◎◎◎ HTTP2
    1. Server push
    2. Multiplexing of requests and responses
    3. Binary framing layer (I don’t understand)
    4. Header compression

    A lazy load
    principle
    When scrolling out distance (scrolltop) + browser window height > target graph height from top of page, change false link to true link
    Reason
    1. Too many pictures are loaded on the page. The network speed is too high, the load is slow, and the traffic is wasted
    2. JS execution may affect normal use after DOM loading
    3. Reduce server pressure
    mode
    Some plugins…

    Using cache
    1. Strong cache

    2. Negotiate cache