3. Three ways to use js

♡After the inline js
binds the event in the html element, you can write the js code directly in the event!
♡Internal js
generally we write script tags in the head tag, and write js code in the script tag.
♡External js
When we use external js, we need to create a file ending with js first.
In the HTML where we want to introduce js, write a script src="path to introduce js"

Guess you like

Origin blog.csdn.net/jq1223/article/details/112727222