Re:Show HN: Reflame – Deploy your React web apps in millisec...
by robertlagrant on Sunday October 09, 2022 @04:22AM
(#33139083)
It would be interesting to include a prenatally hook (or similar) in the developers local npm setup, that pushes what packages are needing to be installed for what commit. That way you're aware of package changes before they even push.
Re:Show HN: Reflame – Deploy your React web apps in millisec...
by lewisl9029 on Sunday October 09, 2022 @12:14PM
(#33142574)
So if a user has the VSCode extension installed, we'd actually install them even earlier than a commit hook could, since we'd install packages as soon as they save the config file. :)
Re:Show HN: Reflame – Deploy your React web apps in millisec...
by robertlagrant on Sunday October 09, 2022 @12:43PM
(#33142832)
Yeah makes sense. Simple but very effective.
Yep, but one important thing to note is this "slow the first time" behavior is limited to npm package installs only. Deploying a ton of source code changes at the same time is still going to be a bit slower than a single module due to sheer network and compute constraints, but the cache is fully granular here, and the processing pipeline is pretty well parallelized so should still take well under a second in most cases. Basically, the only time you should see a slow deploy in Reflame is when you update npm packages (and I hope to change this soon).
And understood re: your desire for reproducible builds, I hope to to add some level of lockfile support in the near future, will let you know through product update emails since you're already signed up! :)
> And if I were starting a greenfield project using Reflame from the get-go, I'd still worry about broader ecosystem compatibility... like if Reflame goes under (god forbid), will my repo still be portable to other buildchains and hosts?
This is a really valid, and probably super common, concern that I can totally empathize with. The best solution I've been able to think of is to make Reflame work seamlessly with existing toolchains, to the point you can have both Reflame and a local toolchain (and possibly another deployment provider that deploys using that toolchain) running on the same codebase simultaneously. This way there ends up being 0 risk to trying out Reflame, since you can run it side-by-side with your existing toolchain to compare, and can always swap back to the local toolchain + deployment provider by just removing Reflame if it doesn't work out.
We're not there yet for the vast majority of toolchains out there (there's a lot of them haha...), but we have built in some preliminary support for create-react-app, so if you have an existing create-react-app project, you can connect Reflame to the repo and it will detect you're using create-react-app, make the necessary config customizations to support it, and will start deploying it without requiring any major code or config changes afterwards. Give that a shot if that would alleviate your concerns around longevity and lock-in!
The next toolchain I'm hoping to do the same for is Vite-based React apps, but definitely open to changing that based on demand!