Remix.run Logo
999900000999 8 hours ago

I actually want browsers to support other languages natively.

Brendan Eich ( the creator of JavaScript) was kind enough chime in that it would be impossible for variety of reasons.

Obviously he knows more about this than me, but I think Google could put Dart in there if they really wanted.

WebAssembly is pretty close though.

simonw 7 hours ago | parent | next [-]

What would "support other languages natively" give you that WebAssembly doesn't?

willseth 7 hours ago | parent | prev | next [-]

Ideally, sure, but that would increase the already enormous burden of building a standards compliant web browser. For a healthy web ecosystem it's important that not only trillion dollar companies can contribute or compete.

999900000999 7 hours ago | parent [-]

Not every single website needs to support every single browser. This is a modern convenience, I was doing QA back in the day when we still had to support Internet explorer.

Internet explorer just didn't provide the same experience as Chrome.

willseth 6 hours ago | parent | next [-]

You were supporting the tail end of an era that is universally agreed upon as an ecosystem failure. The internet didn't provide a consistent user experience for developers or for users, it generated mountains of legacy baggage, and it was frustrating for everyone.

tclancy 7 hours ago | parent | prev [-]

I was doing building and qa when we had to support Netscape Navigator. Not having a varied set of options for browsers comes with clear downsides.

999900000999 5 hours ago | parent [-]

I think we agree ?

For example if Firefox decides to add Rust support it doesn't mean every other browser needs to support it.

Just a handful of web experiences are going to be exclusive to Firefox. As is having Chrome as the only browser most people use isn't great for innovation.

lomase 3 hours ago | parent [-]

Back to Internet Explorer ActiveX times.

kg 5 hours ago | parent | prev [-]

Maintaining a browser is already hard enough, it's a very tough sell to convince 3+ browser vendors to implement a new language with its own standard library and quirks in parallel without a really convincing argument. As of yet, nobody has come up with a convincing enough argument.

Part of why WebAssembly was successful is that it's a way of generating javascript runtime IR instead of a completely new language + standard library - browsers can swap out their JavaScript frontend for a WASM one and reuse all the work they've done, reusing most of their native code generator, debugger, caches, etc. The primitives WASM's MVP exposes are mostly stuff browsers already knew how to do (though over time, it accumulated new features that don't have a comparison point in JS.)

And then WASM itself has basically no standard library, which means you don't have to implement a bunch of new library code to support it, just a relatively small set of JS APIs used to interact with it.

IshKebab 3 hours ago | parent [-]

Webassembly does not generate JavaScript IR. Not sure where you got that idea. Maybe you're thinking of asm.js?