You don't need this on a webpage at all. This is for people making scripts to run on their own computers that just happen to be written in js.
The hash bang at the start of the file tells certain computers that the rest of the file should be run in node. (as opposed to being run as a bash or shell script)
The only change that js runners have made is that they won't error out on a hashbang line at the start of the file since it isn't really js. The js runners will now skip the hashbang and continue below.
Thanks for explaining it further, I really had no idea. Since this article is about Javascript I thought it's something to do with JS in the browser. /u/olvrng maybe put information like that into your article so it makes sense?
3
u/ichsagedir Sep 18 '22
Hashbang is now supported. What is it? Why would you need it? This is not getting explained at all to me.