-
-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Plugin V2.0.0 roadmap #113
Comments
Thanks for the feedback @rosslavery. I've been trialling bundles in my own project for a while now, as I was wanting to have a more granular approach to creating & using functions, rather than the existing approach of one node app exporting all functions. I've tried out webpack, rollup and esbuild and the solution I've found to be best is esbuild. It's great and it 'just works' with Nx. It compiles libraries from source (so they don't have to be buildable anymore), and it supports both es6 modules (which I'm now using) and commonjs too (with es6 having the advantage that compiled functions contain only the code actually referenced in the exported function thanks to tree shaking).
Turns out that it doesn't, if anything it simplifies it, and optimizes too. As long as there's a I've made a bit of progress getting this plugin migrated to it, hoping to have something to show soon. |
The recipe is quite simple if anyone wants to try hacking it around a bit: Install Create a node app in your project:
Then change the
And then in your
Now running This is all ottomh so might be in need of tweaks here and there, but thats the general idea. Next version of plugin will handle all this boilerplate for us. 👍 |
Also, bundling works much better with |
Closing in favour of #116 |
Hi folks, I'm considering some changes to the plugin. Would be great to hear any feedback.
Here are my thoughts for the next major release:
nx g @simondotm/nx-firebase:app
generator will no longer scaffold functions by defaultdeploy
serve
build
commands etc.nx g @simondotm/nx-firebase:function
functions app generatorrollup/webpack/esbuild)The text was updated successfully, but these errors were encountered: