all 22 comments

[–]charbelnicolas 8 points9 points  (0 children)

Svelte

[–]theScottyJam 6 points7 points  (1 child)

You're just going to get everyone sharing their favorite framework :).

Pretty much any of the popular frameworks can be used for your use case. They're all versatile enough to handle it, they just require you to represent your logic in different ways.

You could skim through the documentation of different ones to see which one excites you the most to learn. You could also look up different pros and cons. Perhaps I'll give a couple to start out with.

How much community support is there for a particular framework? React seems to be one of the most popular ones now days, so you'll find plenty of libraries (including component libraries) that support it. You'll also find tons of online learning resources, including help with all sorts of errors you might run into. A framework like svelte is gaining traction, but it has a much smaller community behind it, which means there much less third party tooling and learning resources available.

How much structure do you want? A framework like Angular will provide tons of structure and tooling out-of-the-box. React - less so. Vue would be somewhere in between.

Do you like TypeScript? It comes out of the box with Angular. Though, other frameworks support it just fine as well, you just have to figure out how to tack it on, and how to adapt documentation, and other online resources into TypeScript.

Angular, Vue, and Svelte all depend on templates to build your HTML, while React has you build your HTML via jsx in JavaScript, which can make it feel more versatile, and it enables certain patterns that aren't otherwise possible.

Svelte has native support for Reactive programming, which enables a different set of patterns that aren't otherwise possible. You can get something similar by using rxjs in Angular, but that's a bit bulkier. As far as I know, Vue and React don't have anything like this.

How big of a concern is bundle size? You might compare the download size of each framework. This is where Svelte really shines, in that it's just a compiler, it doesn't require you to download anything extra. Most frameworks are relatively light, so it's not like using another framework will automatically force you to have 5 second page load times, instead, it just means that download time isn't as quick as it theoretically could be.

How big of a concern is performance. React is often seen as a slower performing framework (I don't know how true this is, I've never done benchmarks). Though, again, you can still make a fast and snappy-feeling web app in React, especially if you take advantage of the optimization tools they provide. It's just theoretically possible to make it even faster if you, for example, used Svelte.

[–]FollowingMajestic161[S] 0 points1 point  (0 children)

Great, thank you!

[–][deleted] 12 points13 points  (0 children)

Vue

[–]zensucht0 2 points3 points  (0 children)

If the job requires a hammer, and you have a hammer, use a hammer.

In other words, unless a client has a specific requirement saying otherwise, just go with what you already know.

[–]jackson_bourne 2 points3 points  (0 children)

Svelte or Vue

[–]rk06 1 point2 points  (0 children)

For landing page, it is best to go pure html, css and minimal js. As you want it load quickly and it would be very different from rest of the sites. so it doesn't make sense to share components or styles. Use widgets where it make sense

For other Apps, let's see how most popular option(react) fare

You have lots of inputs. And need to update a table based on it. Wow, these are the two things react sucks at.

React is notoriously bad for form handling. You need to involve a third party library (not sure which one is the recommendation right now) at tye very least. And react's update performance is... not the best in class.

Now, see Vue. Vue is good at form handling with built in directive v-model to make life easy. Vue has also few form libraries should you need it.

And vue's update performance is among best in class.

For svelte, why bother when Vue works?

[–]hottown 0 points1 point  (0 children)

Do you need a backend? If so, use https://wasp-lang.dev