simondotm / nx-firebase

Firebase plugin for Nx Monorepos
https://www.npmjs.com/package/@simondotm/nx-firebase
MIT License
175 stars 31 forks source link

functions only app #107

Closed zpydee closed 1 year ago

zpydee commented 1 year ago

it would be great to have a flag for a functions only app, which would remove bootstrapping for firestore, storage, hosting etc.

Thoughts?

simondotm commented 1 year ago

@zpydee great idea and I'm actually in the middle of writing that exact feature! I've moved over to bundles for my own functions and its a much better experience.

zpydee commented 1 year ago

Ps, thanks for this lib. Really great. To date, I've been following a method described here, but it's failed me with firebase's famous CORS warning when using callable functions. Just sharing for your interest in case it adds any value...

simondotm commented 1 year ago

I gave up on callables and just went with request functions and express APIs. Callables seemed convenient on the client side at first, but I ended up boilerplating an API of sorts in the callable function anyway, and its fairly trivial to pass the JWT in the auth headers than can verified function side with firebase auth lib. I think CORs issues exist on every web project at some point tbh! 😆

zpydee commented 1 year ago

"I think CORs issues exist on every web project at some point tbh" - true that :-)

simondotm commented 1 year ago

Will be possible in #116