News for hackers. Stuff that matters.
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by mbzi on Saturday April 24, 2021 @09:12PM (#26929540)
Good question, still a "green" technology but I have had great successes with it for the past 4-5 years in production (ASM.JS before widespread WASM compatibility).

"promising that we'll be able to build web apps in any language" is not how I see WASM, nor is it really used in this way outside of transpiling Unity3D/Unreal games (this may be the one area there is an exception). I use it to transpile C++ to WASM libraries used within React apps, Edge Lambdas, and Node.JS servers. Primarily down to 2 reasons: speed and efficiency. WASM unlocks excellence and resources in other disciplines/languages such as AI and AR tool chains, Engineers, OpenCV, etc. When used like this, it is outstanding.

What WASM will never be good at is being used for the whole experience. You lose the semantic web, and/or accessibility tooling. Web has some outstanding guidelines and frameworks to help the impaired, screen readers and the like. Using WASM to pump a native app into a HTMLCanvasElement will lose all of these advances, therefore, WASM shouldn't be used for this use case (outside of games). Like all tooling, there is a time and a place to use them.

Below are a few links which use WASM in production:

https://holition.com/play/holition-brings-home-twenty-awards...

https://winners.webbyawards.com/2020/apps-mobile-and-voice/a...

https://www.youniqueproducts.com/beautyguide#.YIS9hOhKguU

https://www.charlottetilbury.com/us/products/charlottes-virt...

https://visagetechnologies.com/demo/

Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by brundolf on Saturday April 24, 2021 @09:29PM (#26929601)
> "promising that we'll be able to build web apps in any language" is not how I see WASM

Unfortunately it kind of got branded this way for people who aren't close to the front-end industry. There's a segment out there who would like to write web apps but aren't willing to touch JavaScript with a ten-foot pole, and their hopes were gotten up that WASM would give them that. It's not exactly a lie, but it has so many asterisks that it may as well be.

In practice, the reality is that JS will continue to be the only first-class language for the web. WASM has many uses, some on the web and some outside of it, but the closer your app is to the DOM and to the browser as a platform, the less likely it is that you'll ever be able to pretend JS doesn't exist.

Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by manigandham on Wednesday April 28, 2021 @12:25PM (#26971173)
Blazor client-side (for dotnet) works fine with minimal asterisks, and even those issues are being slowly solved as WASM evolves with multithreading, GC, and DOM access.
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by the_duke on Saturday April 24, 2021 @10:14PM (#26929814)
In general I agree with your points, but:

> What WASM will never be good at is being used for the whole experience.

The Flutter team would disagree.

They are leaning on WASM for browser builds of Flutter apps, with the whole app rendering in a canvas.

They do accessibility via separately created accessibility trees.

The experience far from great at the moment, but give it a few years and I think it will get there. (better wasm optimisations, direct host interop without JS shims, GC, threads, maybe WGPU instead of canvas, ...)

If that's a good thing for the web is another question...

Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by __float on Saturday April 24, 2021 @11:38PM (#26930172)
Unfortunately, Flutter apps still seem to be lagging on the accessibility front. The Flutter web gallery[0] has many examples of beautiful apps, but something as "simple" (on the web) as being able to select text is absent.

For some use-cases, this is a nonstarter. (Sadly, not to as many as I'd like! But let's simply not regress, to start.)

[0] https://gallery.flutter.dev/

Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by cameronh90 on Sunday April 25, 2021 @06:06AM (#26931588)
It also seems to be lagging on the literal front, at least on my iPad.

Considering these are just hello world apps, the performance has a long way to go.

Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by mhoad on Sunday April 25, 2021 @02:33AM (#26930746)
It’s worth keeping in mind that Flutter for web had its 1.0 release a matter of weeks ago. It’s very impressive with what they have done so far but let’s see where it goes. The amount of potential there is truly huge.
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by sqrt17 on Sunday April 25, 2021 @04:34AM (#26931232)
Agree that it's exciting to see, but what's the actual potential? Flutter developing into a latter-day Macromedia Flash?
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by mhoad on Sunday April 25, 2021 @11:08AM (#26933299)
It’s genuinely hard to tell if you are serious about this or not. Either way it somehow perfectly encapsulated the kind of thing this website is famous for. Congratulations?
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by ksml on Saturday April 24, 2021 @10:31PM (#26929899)
Flutter feels so strange to me. In many ways, it's reimplementing major parts of a browser, compiled to (web)assembly, running inside a browser compiled to assembly... Watch five years from now someone add a low-level programming framework to Flutter and then soneone else reimplement the browser using that
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by refulgentis on Sunday April 25, 2021 @12:28AM (#26930351)
Flutter is a UI framework on top of a low level programming framework, Dart. Sort of like UIKit and Cocoa.
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by iudqnolq on Sunday April 25, 2021 @01:42AM (#26930562)
I think you're thinking of Skia. Dart is a language.
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by refulgentis on Monday April 26, 2021 @05:40PM (#26948555)
Turtles all the way down! It would be more humorous if we used Skia, since that arguably fulfill's OPs proposition that someone would eventually rewrite the browser in said framework
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by mmis1000 on Sunday April 25, 2021 @07:01AM (#26931845)
The flutter web text field don't even handle multiline text input with IME properly. Cause the whole text field to scroll while select character from IME dropdown. I'd doubt how could that be count as "good user experience".
Re:Wasm3 compiles itself (using LLVM/Clang compiled to WASM) by pjmlp on Sunday April 25, 2021 @03:01AM (#26930877)
WebAssembly Summit 2021 was this week, and that is definitely not how the people on the frontline are selling it, BBC is even on the process to fully rewrite they iPlayer in C++.