News for hackers. Stuff that matters.
Re:A day without JavaScript by Touche on Wednesday June 07, 2017 @03:16PM (#14509093)
> Fuck other people running code unnecessarily, without my permission, on my computer.

You gave them permission. Actually, you asked them to do it when you sent that GET request to their servers that returned a bunch of HTML that included script tags.

Re:A day without JavaScript by 801699 on Wednesday June 07, 2017 @04:07PM (#14509473)
Is this really how developers think?

And what if the user does not download the .js file?

And what if the user downloads the .js file but does not run it in an interpreter?

What if the browser authors refuse to process what is enclosed in script tags and to run Javascript?

Maybe they believe it consumes too much memory.

Based on your comment (trolling?), I think maybe Javascript is not the problem. It is developers with thinking such as yours.

If we put inline js or links to .js files in files requested via HTTP, then we cannot claim that users "chose" or gave "permission" to fetch these .js files or to run them. As another commenter stated, those requests were not initiated by the user, but by the browser.

The selection of browsers is small, and made smaller by web developers who promote use of certain browsers i.e., big fat intepreters that will run their needless Javascript. (The keyword is "needless". Almost always users can get the data they seek without running Javascript.)

These "favored" browsers present a massive memory hog and attack surface compared to the minimal tcp client required to retrieve text via HTTP.

Re:A day without JavaScript by bphogan on Wednesday June 07, 2017 @03:19PM (#14509118)
Not really. They gave permission for the initial GET request for the HTML. The rest of the requests were inserted into the document by the programmer and executed by the browser. The browser assumed those links should be fetched automatically and executed. :)
Re:A day without JavaScript by Touche on Wednesday June 07, 2017 @03:49PM (#14509357)
The rest of the requests were triggered by the browser, not the programmer, because they were part of the initial HTML and the browser follows the HTML spec. The person complaining about it and is technical and knows this, they were under no misconception that they were viewing a document format that doesn't include code execution. Of which I'm having trouble of even thinking of an example, because even Word documents can execute code by default.

If you dislike HTML, then don't use it. Use another format that serves your text-only needs. Gopher is a possibility, just don't click on any HTML files if you're using a web browser though.

Re:A day without JavaScript by mnm1 on Thursday June 08, 2017 @03:30PM (#14516523)
No, according to the spec, I can enable / disable JS and not run any code, which I'm doing: https://html.spec.whatwg.org/#enabling-and-disabling-scripti...

So an HTML document viewed in a browser with JS off should not itself run code, ever.

Re:A day without JavaScript by 801699 on Wednesday June 07, 2017 @04:20PM (#14509561)
Trivial to strip HTML tags and produce useful text.

Send all the extraneous garbage you want to the user. She can remove it and keep only what she wants. Meanwhile from the user's perspective you are wasting bandwidth. Who is paying for that bandwidth?

Re:A day without JavaScript by bphogan on Wednesday June 07, 2017 @06:07PM (#14510235)
I was oversimplifying, hense the smiley.

But since you want to argue...

A request to an HTML document with no JavaScript src links, image links, or CSS links will not make multiple requests. I'm old enough to remember when I had to actively tell images to load.

The code for the page is written by programmers. Programmers cause browsers to make multiple requests. Often times without understanding "the spec".

Re:A day without JavaScript by lgas on Wednesday June 07, 2017 @07:30PM (#14510706)
Unless there's a non-JS src link, or a non-CSS link tag, or an xml:base attribute, or an area element with an href attribute, or... you get the idea.
Re:A day without JavaScript by bphogan on Wednesday June 07, 2017 @08:34PM (#14511016)
All things put in by a programmer.

You get my point.