What does the attribute defer/async do when added to the script tag?

What does the attribute defer/async do when added to the script tag?

  1. If async is present: The script is executed asynchronously with the rest of the page (the script will be executed while the page continues the parsing)
  2. If async is not present and defer is present: The script is executed when the page has finished parsing.