6 ms·
The Birth and Death of JavaScript (2014)
- RIshabh235 4mo agoWe’re past the halfway point of Bernhardt’s 2035 timeline; JavaScript hasn’t died yet, but it’s clearly writing its own eulogy in WebAssembly.
- jazz9k 4mo agoI review many sites/month from different clients. They are all using some form of JavaScript. It's like PHP, it will never die.
- fishfasell 4mo agoThe JS death and AI bubble are two events I keep hearing about but will never come.
- inigyou 4mo agoThe AI bubble is now, maybe you mean the AI bubble pop
- fishfasell 4mo agoYes sorry, bubble pop
- varun_ch 4mo agoIt’s also relevant that LLMs have so much JavaScript training data that I don’t see a world where we’re not still using JavaScript.
- lezojeda 4mo ago[dead]
- matt_kantor 4mo ago> It's like PHP, it will never die. I predict that PHP will live a long life, but not as long as C, and I predict JavaScript will have a lifespan closer to C's than PHP's.
- jerf 4mo ago"Death" is hard to define for a programming language. It's tempting to say "the last time anyone writes it", or maybe "runs it", but to put that in biological terms that seems like defining "death" for a person as "the last chemical bond that was part of their body is broken"... sure, it'll happen someday, but all the properties we associate with the term "death" happen rather soon than that.
- wiseowise 4mo agoMultiple generations of your family will be long dead before last JS instruction gets executed. Unless there's going to happen a global thermonuclear war. I still bet on JS surviving over most humans.
- Macha 4mo agoThe same is true of COBOL and Fortran. But also for most purposes, they are practically* dead. * With the one exception of BLAS which is widely used via NumPy
- deleted 4mo ago[deleted]
- DavidPiper 4mo agoI love(?) that he absolutely predicted a global disaster between 2020-2025, he just got the wrong type. Which is very JavaScript.
- noman-land 4mo agoHe was pretty close to being NaN% correct.
- moritzwarhier 4mo agoTo be fair there were a couple of disasters, such as [object Array] and undefined. Feels like the world is hanging on a single thread by now.
- jschrf 4mo agoProtip: never even mention undefined in your codebase. Erase it from your vernacular. If you ever need to pass or return nothing, you use null.
- moritzwarhier 4mo agoI do it this way, but this led to people asking me in reviews why I use NULL^^ My explanation was that it signals intent to me, and is different from some property not being part of the expected object shape or not having been initialized because of some accident or logic failure. Since then, I've sticked to it, and am "allowed" to use NULL ^^ It can lead to some annoying checks in TS for primitively-typed properties, so for these, I still allow explicit usage of undefined when it's simpler given the surrounding code. But I agree with you in principle. Using "undefined" as a "second nullish value" and explicitly checking for it is a programming error. When there's object/areay vs null/undefined, thankfully, the truthiness narrowing often allows me to interface with code relying on "undefined" without explicitly handling this "value" in my own parts of the code base :)
- crdrost 4mo agoIf you're a type purist then undefined looks nicer... It'd be like being upset at booleans because things get coerced to them or some 'ish. No: it's the type that has one inhabitant—it's not that type's fault that it appears as a default argument or var or was left out of JSON... So long as typeof null === "object", null is the absurd one
- Surac 4mo agoMy first contact with js was trying to make a button change its color on mouseover. There was no css back then. I bought a book and was so put off from the syntax that i never looked back to js from that day on. Never regretted my decision
- notesinthefield 4mo agoI had a similar path and never came back to JS until work forced me to learn. To me, it has only gotten more readable.
- julianlam 4mo agos/JS/PHP
- comrade1234 4mo agoI kind of like real JavaScript with prototype inheritance. It's not how we use it in browsers though. And now with typescript and running it in the server... I'd rather just use Java.
- falcor84 4mo agoThe syntax? I got 99 problems with js, but syntax ain't one of them. It's just C-style syntax, no?
- TheOtherHobbes 4mo agoC syntax was never that great. It's basically mnemonic PDP-11 assembler with a few added data structures. js is mutant C with dementia - hacked together over over a fortnight, full of inconsistencies and weird corners. console.log(1 + "2"); // "12" console.log(1 - "2"); // -1 console.log(NaN === NaN); // false console.log(+0 === -0); // true const obj = {}; console.log(obj.foo); // undefined, not an error
- lezojeda 4mo ago[dead]
- oakinnagbe 4mo agoEvery few years, we invent a better JavaScript. Then we transpile it to JavaScript.
- notarobot123 4mo agoMass adoption trumps good design every time.
- jerf 4mo agoIt's all assembly code in the end. There's nothing intrinsically wrong with compiling down to Javascript, a high-level language can still implement many things that direct Javascript does not. Just about every language guarantee you've ever used can be violated by raw assembler.
- deleted 4mo ago[deleted]
- jdw64 4mo agoJS became a compilation target (and it really did), and back then in the video it was asm.js (that's been deprecated, hasn't it?), but then WebAssembly came along... Seeing it actually being implemented and running natively, it seems his prediction was accurate. I mainly use TypeScript myself, and now with Electron, web technologies are wrapped into desktop apps, so web syntax has even entered computer programs. People say Electron is heavy and not great, but it's also the fastest way to support Mac, Windows, and Linux all at once. Sometimes insights like that are surprising. The 'death' being discussed here means that JavaScript becomes the substrate, a state where you don't use it directly, but it's everywhere. And that has truly come to pass.
- _the_inflator 4mo agoJavaScript is the new assembler layer so to say. Every compiler as per definition translates human readable code into machine language. The benefit of JavaScript is, that, after Google really pushed it to its limit with V8 and of course NodeJS made it a backend dream, that it is ubiquitous and once written usable everywhere, much kinda like PDF. Its versatility gave it the advantage over WebAssembly to this day, because it is not as widespread available as JavaScript. I agree with you, that JavaScript itself is nowadays tantamount with TypeScript - what a giant leap this has been. Angular (2) was the unsung hero here. Angular was harshly criticized when they went TypeScript right from the beginning while still offering a native JavaScript version as well (which was basically unusable to be honest). It is funny, that the last hideout not featuring TS as their default option is React, while more and more major integral projects like NextJS rely out of the box on TS. ReactJS will fall, too. It wouldn't be the first time regarding innovations coming from other projects. Again Angular is leading the innovation while ReactJS is a follower. You rarely can go wrong with JavaScript and Python, I would say.
- jdw64 4mo agoYou seem to have said what I was trying to say, but much more eloquently. I also agree with your opinion on Angular. But I like React, so I'm a little sad. Still, I mostly agree with you. The reasons you criticize React are exactly the reasons I love React. Because it changes slowly, even someone like me can keep up. (Just kidding.)
- naveen99 4mo agointerpreted languages carry a lot more context than compiled ones. Sandboxed compiled languages don’t have the context baggage, but come with other parts of the brain dead.
- Dwedit 4mo agoI don't think Javascript is still interpreted though?
- DonHopkins 4mo agoLet's just say it's open to interpretation.
- flufluflufluffy 4mo agoIt is necessarily interpreted. Specific functions or code blocks can be JIT compiled to native code, but not an entire script.
- naveen99 4mo agoSandboxed
- roshiya 4mo ago[dead]
- arkadiytehgraet 4mo agoRegardless of the content, this is one of my most favourite talks ever, especially in the delivery aspect. It served me as an inspiration for quite some time when I had to present anything to a wide audience.
- jhatemyjob 4mo agoSame. I think I watched this 10 times when it first came out.
- marking-time 4mo ago"YavaScript" made me smile.
- j16sdiz 4mo agoI skim though it and saw they had something javascript asm.js in kernel.
- Dwedit 4mo agoThe presentation is a work of speculative fiction presented in a deadpan manner. The things demonstrated in the presentation (Unix shell with C compiler targeting asm.js running inside a web browser) did not actually exist at the time.
- eranation 4mo agoSurprised no one mentioned this is the guy who brought us this masterpiece. If you haven’t seen it, drop everything and watch it, best 5 minutes of your day guaranteed. https://www.destroyallsoftware.com/talks/wat https://www.destroyallsoftware.com/talks/wat
- nosioptar 4mo agoThat's actually fantastic.
- pentacrypt 4mo agoAmazing, thanks!
- sph 4mo agoAll his talks are very good. ‘Boundaries’ is probably the most illuminating video I have ever seen on software architecture, its lessons I still think about when I design any complex application. Incidentally it’s also a great introduction to thinking as a functional programmer if you are used to imperative logic with state spread all over the place. https://www.destroyallsoftware.com/talks/boundaries https://www.destroyallsoftware.com/talks/boundaries
- conartist6 4mo agois there nobody else who thinks "A Whole New World" was the best one?
- flufluflufluffy 4mo agoamazing
- Timwi 4mo agoThere are a few mistakes in this talk; I'll list just two that I noticed. 1. He calls Array(16) and then talks about there being 16 separators. Of course, there are only 15. This kinda breaks the Batman joke. 2. He writes {}+[] and claims that he's adding a list to an object, then mocks the fact that it gives a different result than []+{} which gives [object Object]. In reality, if you write ({}+[]), you also get [object Object]. I'll leave it as a puzzle for you to figure out why {}+[] is different. (Hint: Gurer vf ab bowrpg gurer.)
- satvikpendem 4mo agoThe problem is Wasm is not improving nearly as fast as predicted here. We don't have DOM manipulation so we will still need JS regardless as glue code, or just eschew HTML and CSS altogether and render everything on a canvas as Flutter and some Rust GUIs do but that's a shame to lose the feature set of the web.
- Zigurd 4mo agoPeople choosing Flutter would say the uniformity of a canvas across all browsers is more valuable than gaining the inconsistently implemented web feature set.
- satvikpendem 4mo agoYes that's probably true.
- jansan 4mo agoJS is just so much more approachable than WASM. You can debug it on the fly, feed it to an LLM, there is no wrapper, it's just so much easier to tinker and work with it.
- ifwinterco 4mo agoThe DOM and JS are joined at the hip - the DOM APIs are designed assuming JS is used to access them, and the design of JS and some of its more “unique” features is partly because it was designed for use with the DOM
- ksec 4mo agoAlmost everything happened according to the script. Now we are just waiting for another OS fully based on browser technology or WASM OS. webOS and Firefox OS was at least 20 years ahead of its time.
- moritzwarhier 4mo agoIs there a technical reason you don't mention ChromeOS? Just asking out of curiosity. Also, the screenshots I've seen of webOS makes me long for a revival... not only on smart TVs
- frollogaston 4mo agoNot the parent, but: ChromeOS isn't what I'd call a web-based OS. It supports Android apps, and that's how you get a lot of things that don't have web versions. Not much different from how Ubuntu can run Chrome and also supports native apps.
- moritzwarhier 4mo agoGood point. Since I've never owned a Chromebook, I didn't even know that they are capable of installing arbitrary Android apps.
- nosioptar 4mo agoPersonally, I dont consider chromeos wheb thinking about operating systems because it's not a real os, its a toy released by a shady advertising company. (Same as android.)
- Veserv 4mo agoNot at all. WASM is a repudiation of the thesis, not a confirmation. The thesis is that javascript-compatible source will be the substrate of the future. A javascript engine, though one highly optimized to efficiently interpret a compatible subset, is a potential universal platform of the future despite generic javascript being a terrible substrate. WASM fundamentally rejects this by creating a new javascript-incompatible substrate that is actually designed to be a low level target. Claiming WASM is confirmation of the thesis makes as much sense as claiming that a future where everybody has a Rust interpreter in the browser is confirmation of the thesis. If you are arguing that, then you are just arguing that web browsers will run code in some form in some language as they already do. As the video is clearly discussing a “surprising” possible future, it makes little sense for it to be consistent with literally business as usual and literally every possible future.
- checkthisgot 4mo agoI think JS, is yet to rise the agents, and using all the next.js components.
- jhatemyjob 4mo agoGreat talk. I'm glad he was wrong about this. Having js/wasm be the standard ABI would have been horrible. Obviously he could have never predicted in 2014 that Valve would pour a metric fuckton of resources into improving Wine/Proton, to the point of getting x64 binaries to run on other architectures. But here we are, past the year of the Linux desktop, well on our way to the year of the Linux handset.
- thedelanyo 4mo agoI was actually expecting, typescript takeover.
- cbhl 4mo agoI remember watching Gary Bernhardt give this talk live at the Canadian Undergraduate Software Engineering Conference (CUSEC) back in 2014. PNaCl had just come out the year prior, and Google was using it to cross-compile, run, and sandbox OpenSSH and RDP clients inside of Chrome and ChromeOS, and the Mozilla/Firefox folks counter-proposed asm.js as a response. At the time I just thought it was funny. Now I find it surprising how much of these ideas ended up sticking around.
- devy 4mo agoGary Bernhardt's Wat lightning talk [1] was my favorite of all time. It's only 2 years predates this talk in the title. [1]: https://www.destroyallsoftware.com/talks/wat https://www.destroyallsoftware.com/talks/wat
- bpiroman 4mo agoJavaScript is the greatest programming language of all time.