Previous Episode: 30: Total Elm
Next Episode: 32: Elm Routing

My thesis is that in a few short years JavaScript will be considered in the same realm as programming in C. Meaning to write an application in JavaScript will be considered “mid level”, error prone, dangerous (dangling pointers), lowest common denominator, and only really used when you need to leverage a specific use case.

C Lang JavaScript operating systems everywhere the web everywhere Compile Target Compile Target Null references Undefined Performance Yeah, JS is stupid fast too JavaScript is the new C JavaScript is Dead, long live JavaScript Used to be really straight forward to get started with JS. Open a text editor / browser and write some code. JS ecosystem now has task runners, bundlers, transformers, CommonJS / ES Modules, minify, source maps, package management w/ npm, dev servers, prod performance builds, virtual DOM rendering, V8 performance, I would contest that JS has never been an is “easy” language to master, but an easy platform to be productive in. With the list above, I believe that easability is now gone.

Languages that interact with C, but would you want to write your next application in C?

C++ Java Golang C# Python Haskell Objective C

Languages that interact with JS, but would you want to write your next application in JS?

Elm. Elm is a purely functional programming language that compiles to JS, HTML, and CSS. … Dart. Read Modern JavaScript. … TypeScript. TypeScript is a superset of JavaScript; a valid JavaScript program is also valid TypeScript but adding static typing. … PureScript. … CoffeeScript. … ClojureScript. … Scala.js. … Reason… and on and on… Is it that silly of a question ? We’ve seen the recent explosion of languages that currently target JS to enable them take advantage of not just the web, but the ecosystem that comes with JS, PORTS cough cough
Languages that are built as supersets of C and JS have a common theme, “to overcome perceived shortcomings of C/JavaScript”

Where does web assembly fit in all this?

Well, this transition to higher level languages that compile to JS, has been happening for roughly 10 years now. And it’s just now, I think, reaching a tipping point of main stream. Look at us here! We have just barely begun to scratch the surface of this potential. I want wasm today too, but sadly it will like be years before we see the fruits of labor happening in that space now. But man it’s so cool to follow.

From the author himself, circa 2011

“The new “better is better” hope for multiple languages is NaCl. It was the driver for the Pepper API that failed by being too chromium-specific. Hope springs eternal, but IMHO the C/C++ toolchains will have CFI enforcement for portable safe binary code sooner than the browser vendors will agree on NaCl and Pepper2 or 3.The “worse is better” hope is compilation to JS combined with language and VM evolution. That is my bet. And I am putting money on it at Mozilla.”

Link

JavaScript++

I rest my case! Picks Typeclasses Learning FP Create and share beautiful images of your source code. Jay Phelps talks about WebAssembly, discussing what it is, how it can be used today, and the opportunities it will unlock in the years to come. Resources In mid-2011, the new C++ standard (dubbed C++11) was finished. C++ 2011? Compiling to JS JS is Assembly for the Web CoffeeScript 2009 V1 JS++ is a thing! Compile to JS Follow

JavaScript to Elm

Twitter: @jstoelm
Email: [email protected]

Jesse Tomchak

Twitter: @jtomchak

 

Twitter Mentions