The order of browser parsing of html, js, css

1. In general, it is loaded in the order of html documents

2. Also, it is best to put both internal and external JS files after all html content, this will make users feel that the page loading speed becomes faster, otherwise if all external files (including css and JS) are referenced Medium, which means that you must wait until all the JS code has been downloaded, parsed and executed before you can start rendering the content of the page (when the browser encounters it), which will cause a significant delay in rendering the page. Second, the browser during the delay The window will be blank.

Browser loading order and execution of HTML, CSS, and JS files

Guess you like

Origin blog.csdn.net/qq_39004843/article/details/114253463