8 ms·
Solid is another smart-compiler, virtual-dom-less frontend component building library. If you're wondering how this is different from Svelte, the author has a
by hardwaresofton 6y ago
Solid is another smart-compiler, virtual-dom-less frontend component building library.
If you're wondering how this is different from Svelte, the author has a Medium post on it[0].
[0]: https://medium.com/@ryansolid/javascript-ui-compilers-comparing-svelte-and-solid-cbcba2120cea https://medium.com/@ryansolid/javascript-ui-compilers-compar...
- jadbox 6y agoOne thing the article doesn't really dive too far into is that Svelte is template driven, while Solid is more about React's jsx-drive-components. As I've used both style methods for years, I think I'm growing fond of Svelte's template approach as the best general purpose solution. This is because usually my pages are 70% static and can be expressed as simple nearly vanilla web-idiomatic html pages. Being able to keep all that static code as close to vanilla web really helps to reduce other overall complexity, with the added benefit of being able to copy html with css from anywhere into my project, and then add dynamic behavior without "rewriting" basic html into jsx (which can lead to subtle bugs).
- ryansolid 6y agoWe use JSX identical to a Template DSL more or less. We don't use JSX at all like React does. That's why Solid so performant. It does similar thing to Svelte. We don't compile it into HyperScript. You can copy and paste html with one exception (void elements JSX makes you close input tags etc). But otherwise I support all the standard stuff pre-adding the dynamic bits. Solid supports `class` and `for` and `style` strings etc..
- schwartzworld 6y ago> This is because usually my pages are 70% static and can be expressed as simple nearly vanilla web-idiomatic html pages. React can easily be used to render just the parts of the page that need it, with all the surrounding html done the old fashioned way.