Импорт JS в HTML
<script type="text/javascript" src="yourfile.js"></script>
SteDeus
<script type="text/javascript" src="yourfile.js"></script>
<script type="text/javascript" src="/path/to/script.js"></script>
<script src="index.js"></script>
<script type="text/javascript" src="path-to-javascript-file.js"></script>
<script src="Your-JavaScript-File.js"></script> <!--If JS file is in same folder with HTML file-->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Embedding JavaScript Externally</title>
</head>
<body>
<p> Embedding JavaScript to HTML externally </p>
<script src="index.js"></script>
</body>
</html>