Earlier quoted context omitted.
Speaking about size reduction, I once had a client who want me to update his product as it became extremely slow and buggy. The product was an MS Word Add-In that was run on an MS Surface which takes shots using webcam and insert them into the active document, it was built in .Net and the previous developer used, as I recall, OpenCV library to take the shots. The installation binary was around 300MB! And, to add insu…
How old was the Add-In? Did the tiny lib you used exist back then and did it support the Surface webcam?
Svelte 4
131–140 of 227 posts
Re: Svelte 4
#132This is odd timing with Rich Harris just releasing a course on Svelte v3 on Frontend Masters (June 12th 2023). https://frontendmasters.com/courses/svelte-v2/ From the migration there does appear to be some breaking changes, don't know how that aligns with the course which I planned to take. His old course was good as well, but that relied on Sapper.
I don't think you learn anything that wouldn't apply to Svelte 4. It's intended as a smaller update to prep them for bigger changes coming in Svelte 5.
Re: Svelte 4
#133Time for a very naive question. As somebody looking for a more effcient (less re-rendering) and nicer DX (template based, stuff like exit animations) alternative to React, what actually makes Svelte measurably better than Vue? On first (and very naive) look the two seem pretty similar, with the biggest difference being that Vue seems to have the much bigger ecosystem and more mature tooling (I keep hearing about Svel…
The performance difference is huge. A few years ago I launched an interactive consumer app on very resource constrained devices that would have been impossible with React or Vue (I empirically tested both). Think dual or quad core 1Ghz arm processors with zero GPU acceleration running electron . The only optimization I had to implement was virtualization when showing hundreds of off screen images (an optimization I w…
Re: Svelte 4
#134is there a way to host learn.svelte.dev locally ? like git clone repo and then npm run dev ?
Re: Svelte 4
#135Basically I'd need the ability to drag and drop, move the tree around like a Map, detect clicks to add new nodes and new branches, stuff like that. I'm thinking an HTML5 canvas would be best but idk.
Re: Svelte 4
#136> Svelte 4 reduces the Svelte package size by nearly 75% (10.6 MB down to 2.8 MB), which means less waiting on npm install. This improvement will be especially noticeable for users who are loading our interactive learning experience on learn.svelte.dev for the first time, users of the Svelte REPL, and users with limited connectivity. The majority of the remaining package size is eslint support, which necessitates dis…
I'm used to Svelte, and I remember last year when I tried to install a basic NextJS starter template (create-nextjs-app) I had to wait a minute or so for all the npm dependencies to install. I then checked my project folder and it was 600MB....mindblowingly bloated.
Re: Svelte 4
#137Time for a very naive question. As somebody looking for a more effcient (less re-rendering) and nicer DX (template based, stuff like exit animations) alternative to React, what actually makes Svelte measurably better than Vue? On first (and very naive) look the two seem pretty similar, with the biggest difference being that Vue seems to have the much bigger ecosystem and more mature tooling (I keep hearing about Svel…
Vue 3 is kind of dead. Almost no features in the last year. Look at the GitHub repo, little activity, mostly maintenance stuff. I suspect author (Evan) lost interest, given the Vue 2/3 situation (similar to Python 2/3) and the lost battle against React.
Re: Svelte 4
#138Earlier quoted context omitted.
I'm used to Svelte, and I remember last year when I tried to install a basic NextJS starter template (create-nextjs-app) I had to wait a minute or so for all the npm dependencies to install. I then checked my project folder and it was 600MB....mindblowingly bloated.
and totally irrelevant. how is having 600mb of dependencies making your life so much harder compared to time savings and developer experience Nextjs provides
Re: Svelte 4
#139Earlier quoted context omitted.
yea but this more like install react more than nextjs, nextjs do to much magic to be comparable 600 mb is insane anyway but is important to be clear then we are comparing different things
Would SvelteKit be a better comparison then?
Re: Svelte 4
#140Could someone give a one or two sentence explanation of why I would want to use Svelte over something like React? I have heard it is "better", but have never understood why.
This is always a personal judgement, but here's my personal list: - I find it so much easier to understand. I don't have to useState/useEffect/whatever, I just assign variables and the component re-renders the relevant parts whenever I assign a new value. - Styling is "just" CSS. No messing around with CSS-in-JS libraries and their various ways of being invoked. The CSS is automatically scoped to your component witho…
I also don't understand the styling complaint. React devs used "just CSS" for years before some of them started pushing for CSS-in-JS. In fact, SCSS/CSS is the default for the still nearly ubiquitous create react app system.
End-user bundle argument is a red herring. What is true for "hello world" isn't true for large applications. The overhead of React is a one-time payment while each new Svelte component drags along all the code needed to support it (copying similar code over and over).
React's F + N * C (where F is framework size, N is component count, and C is average component size) is smaller for large values of N than Svelte's N * (F + C) approach.