[1] https://github.com/Kotlin/kotlinx.html/blob/master/README.md
Kotlin solves this by using the programming language for the whole thing, allowing you to extract repeating parts using plain functions as you would with any other code. Of course it's not as well suited as HTML itself for writing HTML, but it might be better than HTML + some template language + some programming language.
Another way to go, to avoid having a mysterious mixture of almost-HTML embedded within some other syntax, is to do what Thymeleaf does[1] and have the template language be embedded inside HTML (rather than the other way around) so that the template file is actually valid HTML.
[1] https://www.thymeleaf.org/doc/tutorials/2.1/usingthymeleaf.h...
A react app has massive abstraction to render on every frame, Svelte compiles out the framework to render instant straight vanilla js (wins all perf tests).
Pre-compiling allows for beautiful syntax and more flexible app structure, since you aren't limited to the runtime.
SSR and code-splitting are significantly easier and more straightforward.
React is designed for a billion-user site and it shows.
There really is zero cost to pre-compiling except mind-share, and only benefits. Of course an F100 company has many concerns above tech awesomeness, so no judgement on your selection criteria. But I assure you this movement is coming, react/vue/angular will adapt/change and/or people will move to Svelte-like solutions.
You can already see it happening in the article facebook released today [1]:
"By using rems, we can respect user-specified defaults and are able to provide controls for customizing font size without requiring changes to the stylesheet. Designs, however, are usually created using CSS pixel values. Manually converting to rems adds engineering overhead and the potential for bugs, so we have our build tool do this conversion for us."
I highly doubt that one can build a ReactJS app that loads faster than a Svelte one. I encourage you to try and share it. This is coming from someone that is a backend engineer that doesn't really do JS, but have had to for my own personal project and both perf and the subjective bit of expressiveness and joy of writing are important. Contrary to popular belief, people think that Svelte is trading perf for ugliness and lack of expressiveness.
Looking at the framework benchmarks (https://krausest.github.io/js-framework-benchmark/current.ht...), svelte is indeed a good bit faster than React. However, Inferno which takes a react-like virtual DOM approach but better optimised is faster still. So I'd be more inclined to go with that if I were willing to give up the React library ecosystem.
1) Their app is pretty small
2) Their machine is really fast
Also same ecosystem story there: redux-saga, redux-form, etc are all low/no budget projects.
However, Dan and Andrew haven't actively touched Redux library code since mid-2016. (Dan occasionally drops into an issue to comment, like his suggestion to not ship a `useActions` hook for React-Redux, but that's it.
The _current_ maintainers (Tim Dorr and myself) do not work for Facebook, and Redux has never been a Facebook-sponsored project. We're an independent open source project.
We chat with the React team frequently via Github and Twitter and such, but that's just OSS collaboration work.
See https://blog.isquaredsoftware.com/2018/03/redux-not-dead-yet... for more details.
I don't do JavaScript professionally anymore, but I've worked with jQuery, BackboneJS, lots of AngularJS, some Elm, some VueJS, and some React, but being the curious person that I am, in search of greener pastures, I checked out Svelte, by first watching Rich Harris' video https://www.youtube.com/watch?v=AdNJ3fydeao on "Thinking Reactivity", then seeing the benchmarks: https://twitter.com/Rich_Harris/status/1200807516529147904, and watching Rich and Dan Abramov spar a bit over their challenges. From an outsider with no skin in the JS game, it is clear that Svelte seems far superior now and into the future...
1. it is a compiler (it's like comparing C/C++ to Python) 2. the joy of out-of-the-box animations that use the GPU in CSS (reminds me of the joy of using jQuery for the first time w/ it's OOB animations) 3. you can drop in any other JS lib (doesn't have to be in a particular JS framework ecosystem) and have it inter-op! This is huge! It's because it's literally like writing vanilla JS 4. no need to learn some new syntax like JSX (not a huge fan)
Just take a peek. If you don't like Svelte, so be it, but at least you know what it is that you don't like rather than turning a blind eye because you don't want to be convinced -- that's tunnel vision.
I was trying to decide between React/Vue/Svelte for a project I started recently, and after having attempted to build to-do apps in each, I landed on Svelte.
You want to turn this into a framework/lib debate? I'm checking out. Angular is popular in the same vein that PHP is popular. People still use it. In fact, CodeIgniter is still very popular. It certainly has some use cases that certainly beat things like Rails, too. I see where you're going with this -- you care about popularity. Got it. Well, Svelte will check out now.
I could care less for any framework. I'm looking for the least friction, highest expressiveness, maintainability, and last, but not least, portability.
I just left a company that did React having spent the last year ripping out Nuclear for Redux and now there are React Hooks and Contexts. Hire massive teams to spin wheels rather than feature development and chalk it all up to tech debt sounds like fun.
WhatsApp would not exist if people didn't use more obscure technologies. 50 person team on Erlang for nearly a billion-user product while some organizations want to run 500 person teams to refactor the code written only a year ago be it Java or JavaScript.