4 ms·
Yes, it really does. It means that you can use component style development while having a regular server-rendered app. If/when you want some interactivity, you
by mdasen 3y ago
Yes, it really does. It means that you can use component style development while having a regular server-rendered app. If/when you want some interactivity, you can add it simply without much effort. With .NET 8's Blazor, you can just have regular pages for 90% of your stuff and just use WASM (or websockets) for 10% of stuff. The good thing here is that you get fast initial page loads and navigation and the disadvantages of WASM are a lot smaller (like larger downloads than JS since it's shipping a GC and such).
.NET is following the WASM GC stuff. There are some Post-MVP features for WASM GC that will benefit .NET. Note, I'm not an expert on this and this is coming from memory. That said, .NET has some features that won't be supported well by the WASM GC MVP. There's always a trade-off between supporting more and getting stuff out into the world so that languages that might not need the features can start using it (and they can learn from the usage which will benefit everyone). For example, .NET allows more pointer stuff than a lot of GC'd languages. .NET's `unsafe` isn't used much by most .NET programmers, but it is there. I think maybe .NET has stronger guarantees around finalizers than Java (where they aren't guaranteed to ever be run). The WASM GC is just an MVP at this point, but it has landed and they're working on its future. It really feels like we're getting to that point where WASM is going to really offer a better experience in the near future.
Ultimately, the timing of WASM GC wouldn't work out for the .NET 8 timetable, but I'd expect there to be a lot of work on it for .NET 9 next year. It's possible that a lot of Post-MVP stuff will land in WASM GC to help .NET and there's probably some opportunity to make Blazor work around other stuff. I think they haven't mentioned it or put it on the roadmap because they're still figuring out how it's going to go (and we'll probably know more in like February). But they are certainly looking at WASM GC and it's likely to offer a nice boost for .NET 9.