Svelte – The magical disappearing UI framework
I&#x27;m confused by the anti-runtime argument.<p>The file size problem is about unused code, right? If we tree-shook the runtime and shipped the minimal version that our app needs, wouldn&#x27;t that be even <i>better</i> for most apps than inlining the framework? I&#x27;d expect that, the moment you use a feature even <i>twice</i>, the runtime approach yields a smaller bundle.<p>Or is Svelte accepting a file size penalty to avoid the performance overhead of function calls? If so, it&#x27;d be nice to see that tradeoff discussed more explicitly: in every app, there are probably features worth inlining and features worth keeping as function calls.<p>Really, it sounds like Svelte is trying to solve a very general compilers problem with a very specific sledgehammer solution. Sure, tree-shaking and thoughtful inlining are difficult to do well, especially in Javascript, so this makes sense as a first draft for certain use cases. I just wish it were touted as a first draft, rather than a new beautiful finished paradigm.