3 ms·
As I said most of this is subjective so I won’t disagree but: > copying similar code over and over This isn’t true. Svelte is more than capable of reusing cod
by afavour 3y ago
As I said most of this is subjective so I won’t disagree but:
> copying similar code over and over
This isn’t true. Svelte is more than capable of reusing code internally.
- hajile 3y agoWhat code does Svelte use internally vs what code winds up compiled into your components? Last I checked, MOST of the code wound up in your components. In fact, this was their entire argument for why people should use Svelte when it launched. Just look at their "Hello World" application on the Svelte website. 5 lines of code transform into 45 lines of code.
- afavour 3y agoIf two components use the same code it’s hoisted and both components use the same function declaration.