Hacker News new | ask | show | jobs
by roadbeats 2853 days ago
I’m an happy Elm user; but I wonder if it’s a worth investment to start using Elm when we’re heading to a new ecosystem on top of WebAssembly. I use Go on backend, and would feel satisfied when Go and Webassembly works together fine.
3 comments

To target the web, you need a team dedicated to building HTML library stuff like interaction with the DOM. It's unclear whether Go even has that, and it will take longer to see if it proves popular, so waiting for Go for generic UI seems very premature.

On the other hand, Elm is not 1.0 yet. They are still breaking the ecosystem with new releases.

WebAssembly is still far away from being any sort of default for web development yet (if only because IE11 doesn't support it).

I also wouldn't be surprised if Elm compiled to wasm in the future.

It's openly a desired/considered goal for Elm to compile to wasm.
I know, I'm one of the people looking into it.
Oh, haha! Cool.
Most compilers that target WebAssembly can also target asm.js, which is compatible with IE.

AFAIK it's more about missing stuff like DOM access and GC that stands in the way.

> Most compilers that target WebAssembly can also target asm.js, which is compatible with IE.

asm.js is different enough that it's just not about adding a seperate asmjs "compatibility" target. On the top of my head you don't have 64-bit ints or floats and I believe the way you call asm.js fns from/to JS is different from wasm. Adding asm.js support just for IE 11 wouldn't be worth the effort.

At present, Elm compiles to javascript. But when the time is right, it will have other compilation targets as well, e.g Webaassmebly