HTML/CSSIntermediate#html#performance#scripts

What is the difference between <script>, <script async>, and <script defer>?

Plain <script> blocks HTML parsing while it downloads and executes. async downloads in parallel and executes as soon as ready (out of order), still blocking parsing briefly. defer downloads in parallel but executes only after parsing completes, in document order — best for most scripts.

Example
<script src="analytics.js" async></script>
<script src="app.js" defer></script>

Related Questions

1
HTML/CSSBeginner#html#forms

What HTML5 form input types do you know?

Open
2
HTML/CSSIntermediate#html#forms

How do you validate a form using native HTML attributes?

Open
3
HTML/CSSBeginner#html#forms

What is the difference between GET and POST form methods?

Open