Native GUIs are fast, but they are not powerful. You have to specify a fixed resolution, fixed size, and more often than not calculate the layout yourself, or use very limited auto-layout features.
The web browser gives you a full package with standardized commands to control all those aspects, which is also portable between different implementations.
If your rendering needs are limited to a few buttons and a canvas on a fixed size, sure, go native GUI. But if you need to support multiple devices and resolutions, on-the-fly resizing, and layout of multiple complex screen sections, the browser is an unbeatable platform.
I use both svelte and WinForms at my day job.
The designer works quite well initially for laying out the groundwork but after a while it becomes a burden:
- components randomly disappearing but still being there when running the program
- designer crashes
- Small changes that require you to manually drag around 60% of the form, to add or remove one field
Svelte ain't perfect and it requires more scaffolding initially but you get:
- actually good data bindings and state management (in many places you would need event handlers for winforms)
- hot reload (very big win)
- the ability to do greater layout changes with a few css lines (in combination with hot reload quite pleasant to style)
- mass styling without selecting every component every time you want to change something
- native async/await integration in the ui framework
plus the rest of the benefits (not DX oriented)
- gpu rendered instead of cpu rendered
- runs on any OS (including phones)
- advanced responsiveness via CSS
(sorry for the poor text layout, didn't yet find a way to insert line breaks without them being removed)
For smaller apps (dozen input fields or so) the WinForms designer (which has been on life support for well over a decade now!) will get the job done better than anything else out there.
If you want GPU rendered, WPF has you covered. I strongly dislike XAML, even though I like JSX (while disliking data handling in react in general).
The thing about responsiveness is I can make 6 UIs in WinForms faster than I can fix cross platform CSS bugs.
The real issue is WinForms isn't cross platform. :(
Easy to use initially, because of the designer. But as the application scales, it becomes more and more painful. Thinking about components randomly disappearing but still being there, designer crashes. Small changes that require you to manually drag around 60% of the form, to add or remove one field.
I think poster is trying to stay that too many styling options has made for worse UX.
Users can get used to ugly and consistent. On the web and mobile, there is minimal consistency of what a button even looks like, or where site options are to be found, every site looks different and every company has its own style guide.
>Worse developer experience and worse style options though
reply
But better user experience.
Also many styling options are counterproductive for the UX.
Yeah... JS and the DOM are incredibly fast, but that does not applications written for that platform are fast. Many JS developers have absolutely no idea how these technologies work and are reliant upon several layers of abstractions that are each progressively slower than the next.
As an analogy crypto coin in theory is a good idea, but its rife with fraud because most people playing with crypto are speculators that have no idea what they are doing.
You're totally right about the layers of abstraction... still, JS and DOM could be incredibly fast (and in some way, they are, sa there are huge optimizations behind for that to work as well), but they remain slower and more energy hungry than (almost) any native interface, even if you leave away all the layers of abstractions.
Native GUIs are fast, but they are not powerful. You have to specify a fixed resolution, fixed size, and more often than not calculate the layout yourself, or use very limited auto-layout features.
The web browser gives you a full package with standardized commands to control all those aspects, which is also portable between different implementations.
If your rendering needs are limited to a few buttons and a canvas on a fixed size, sure, go native GUI. But if you need to support multiple devices and resolutions, on-the-fly resizing, and layout of multiple complex screen sections, the browser is an unbeatable platform.
> You have to specify a fixed resolution, fixed size, and more often than not calculate the layout yourself, or use very limited auto-layout features.
Even Java UIs supported dynamic layouts 20 years ago.
C# had a flex box based layout (called flow layout) since 2006.
Worse developer experience and worse style options though
A few years back I prototyped a b2b web app using winforms.
At this point in time I'd been writing react for 2 years non stop and I hadn't used winforms for at least 5 years.
I started up visual studio, and used the GUI builder to make a fully featured data bound winforms app connected to my backend in less than a day.
2 months later I had the react version up and running.
Was the react version shinier?
Yes.
But the web development experience is literally orders of magnitude worse.
I use both svelte and WinForms at my day job. The designer works quite well initially for laying out the groundwork but after a while it becomes a burden: - components randomly disappearing but still being there when running the program - designer crashes - Small changes that require you to manually drag around 60% of the form, to add or remove one field
Svelte ain't perfect and it requires more scaffolding initially but you get: - actually good data bindings and state management (in many places you would need event handlers for winforms) - hot reload (very big win) - the ability to do greater layout changes with a few css lines (in combination with hot reload quite pleasant to style) - mass styling without selecting every component every time you want to change something - native async/await integration in the ui framework
plus the rest of the benefits (not DX oriented) - gpu rendered instead of cpu rendered - runs on any OS (including phones) - advanced responsiveness via CSS
(sorry for the poor text layout, didn't yet find a way to insert line breaks without them being removed)
Svelte is my go to on the web as well.
For smaller apps (dozen input fields or so) the WinForms designer (which has been on life support for well over a decade now!) will get the job done better than anything else out there.
If you want GPU rendered, WPF has you covered. I strongly dislike XAML, even though I like JSX (while disliking data handling in react in general).
The thing about responsiveness is I can make 6 UIs in WinForms faster than I can fix cross platform CSS bugs.
The real issue is WinForms isn't cross platform. :(
I strongly disagree with that. WinForms is imho very easy to use.
Easy to use initially, because of the designer. But as the application scales, it becomes more and more painful. Thinking about components randomly disappearing but still being there, designer crashes. Small changes that require you to manually drag around 60% of the form, to add or remove one field.
Better user experience and many styling options are counterproductive for the UX.
Better user experience (UX) is counterproductive for the UX... wut
I think poster is trying to stay that too many styling options has made for worse UX.
Users can get used to ugly and consistent. On the web and mobile, there is minimal consistency of what a button even looks like, or where site options are to be found, every site looks different and every company has its own style guide.
>Worse developer experience and worse style options though reply But better user experience. Also many styling options are counterproductive for the UX.
Now it's more understandable what I tried to say.
Qt had what is essentially flexbox in early 2000s.
Native apps have had to deal with dynamic sizes and layouts since the idea of resizing windows to arbitrary sizes became a thing. So, since 1980s?
> on-the-fly resizing
Which web tech famously cannot do with any efficiency
> and layout of multiple complex screen sections
What complex screen sections? This is a complex screen section: https://x.com/dmitriid/status/1424052288205856773
The web does not (and cannot) have "complex screen sections". It doesn't have the capacity for it.
Fixed resolution and size? Manual layout calculations? What was the last native GUI toolkit you used, Win32?
Yeah... JS and the DOM are incredibly fast, but that does not applications written for that platform are fast. Many JS developers have absolutely no idea how these technologies work and are reliant upon several layers of abstractions that are each progressively slower than the next.
As an analogy crypto coin in theory is a good idea, but its rife with fraud because most people playing with crypto are speculators that have no idea what they are doing.
You're totally right about the layers of abstraction... still, JS and DOM could be incredibly fast (and in some way, they are, sa there are huge optimizations behind for that to work as well), but they remain slower and more energy hungry than (almost) any native interface, even if you leave away all the layers of abstractions.