2 ms·
The most important thing for me is rapid development with no surprises and package churn, since I'm either trying to get an MVP out ASAP, or I'm trying to deliv
by tofukid 5y ago
The most important thing for me is rapid development with no surprises and package churn, since I'm either trying to get an MVP out ASAP, or I'm trying to deliver under a deadline for a client.
Here's an example of a working app using my approach I described above: https://jsbin.com/putonutica/edit?js,output https://jsbin.com/putonutica/edit?js,output
The two functions, render and dispatch, are essentially the only code I share across the projects. That's the whole "framework". It's 19 lines of code. All it requires is a link to Preact, which is 14K. Oh, and I just keep everything in one big file. Simple, but I've built multiple complex single-page JS apps with this approach.
I'm sure someone will tell me I'm doing it all wrong, and I need to use Next.js with webpack, a giant stack of npm packages, code-splitting and bundling, and whatever craziness front-end developers are doing today.
- Zababa 5y agoThanks for the example. You're right about package churn, especially if you're working alone. You don't want to spend all your time updating dependencies. Not having a build step must be a breath of fresh air too.