How to get all the script tags from HTML documents using JavaScript?
Originally posted here!
To get all the script tags from an HTML document or the DOM, you can use the document.scripts property.
Let's say you have many script tags in your HTML file like this,
<script src="script1.js"></script>
<script src="script2....
melvingeorge-me.hashnode.dev1 min read