firebase-tools icon indicating copy to clipboard operation
firebase-tools copied to clipboard

On-change re-compilation of cloud functions when working with TypeScript via Emulator

Open deve-sh opened this issue 1 year ago • 0 comments

Description

I noticed when serving Cloud Functions written in TypeScript via the Firebase Emulator, that my changes were not getting recompiled and I had to run npm run serve each time I made a change for them to take effect.

This change adds a --watch parameter to npm run build script supported natively by the installed TypeScript version, and runs the command in parallel to firebase emulators:start --only functions so one doesn't have to re-run the npm run serve script each time a change is made.

deve-sh avatar Mar 08 '24 16:03 deve-sh