5dfea485d4b42aad0951dee7ca6377a5e649ff16
[kill9.git] / harmful / software / javascript.md
1 # JavaScript and its consequences have been a disaster for the human race
2
3 OR: Manmade virus infecting the world.
4
5 JavaScript is a programming language often used on websites. To create
6 dynamic content on client end. Some dudes thought that extracting the
7 V8 (chromium javascript interpreter) and making it a executable file
8 to run javascript outside the browser was a good idea and now we're
9 doomed.
10
11 JavaScript is not only stupid (javascript returns true when) ```true +
12 true === 2``` Which means that true is literally ```#define true 1```
13
14 At the end that doesn't matters. Because it's a useless fact to be
15 honest. It only shows how bad designed the shit is. But the pain starts
16 when you actually use that programming language.
17
18 ## Developers idiocy
19
20 First of all the language is slow as fuck. And websites are BLOATED of
21 JavaScript nowadays. Adding ***USELESS*** function i'd never like to
22 use, or functions I already disabled on my browser. Such as smooth
23 scrolling. I hate smooth scrolling. But some websites force me to use
24 it because JavaScript.
25
26 Not to mention the fucking thing runs like shit because developers
27 don't really know how to write this abyss programming language. For
28 example, In a good browser (pale moon), Javascript runs like shit
29 (IT'S A FEATURE). No I mean, literally, Tweetdeck runs 100 times
30 better than fucking regular twitter.com.
31
32 And remember, if you use a good browser (pale moon), which has slow
33 javascript interpretation, haha! good luck browsing the web with
34 javascript enabled! it will be fucking impossible
35
36 ## Idiocy examples
37
38 ~~~
39
40 <true + true === 2
41 >true
42 <true == "1"
43 >true
44 <false == 0
45 >true
46 <false == "0"
47 >true
48
49 <'0' == 0
50 >true
51
52 <'\t' == 0
53 >true
54 <[] == 0
55 >true
56 <'\t' == []
57 >false
58
59 <false == undefined
60 >false
61 >false == null
62 <false
63
64 <null == undefined
65 >true
66
67 // I specially like this one
68
69 <[]+{}
70 >"[object Object]"
71 <{}+[]
72 >0
73
74 ~~~
75
76 # Disabling JavaScript
77
78 Unless you only use 1.0 websites. Disabling javascript will broke your
79 internet experience, but will make it way faster. just install
80 noscript and have fun with your sane browser.
81
82 # NodeJS
83
84 Node is what happens when you extract the JavaScript interpreter from
85 chromium and put it on the desktop. This allows the user to execute
86 .js files on the desktop without a browser. Which is stupid. A web
87 programming language shouldn't be on desktop. Just on the web. But
88 thanks to this great idea we've now worse things
89
90 (Node isn't even a JavaScript implementation. It is just the V8 engine
91 outside the Chromium browser. Meaning that node is just a part of
92 chromium with marketing)
93
94 # Syntax
95 The syntax was written by a gorilla, it uses camelCase, (I don't
96 like it, but well, i can live with it).
97
98 for example, `in JS you do document.getElementById("foobar");` I guess
99 this is ok, but like I said, this was written by a monkey, becuase
100 then we have functions: `XMLHttpRequest` <-- What the hell? Why is
101 XML capitalized, but Http isn't? A good language, let's say, C, would
102 have done it like this: `xml_http_request`; (which is saner)
103 or `XML_http_request()` if you use the weird OpenSSL functions names lol
104
105
106 # Electron
107
108 Electron is what happens when you hire web developers but you gotta
109 make the program aviable for the desktop. The problem is that
110 JavaScript can't do graphics (as far as I know, there's no X11 library
111 for JavaScript, thankfully) So what do they do to use GUIs on
112 JavaScript? Make every program a mini-chromium browser! So every
113 program that's running electron is just chromium browser. Which is
114 truly stupid. And a lazy way to do programming.
115
116 Here's what is needed to run a program (Written in a compiled language) in GNU/Linux:
117
118 <img src="C.png" width=300>
119
120 And this is what is needed to run a program written in electron:
121
122 <img src="Electron.png" width=300>
123
124 # Links
125
126 [JAVASCRIPT WAS A MISTAKE](http://www.bordi.ga/blog_shit/js.html)
127
128 ![Tom Araya can't scream like i'm internally screaming
129 rn](/1592614085502.png)