Open vicary opened 2 years ago
Hmm doesn't invoke local immediately invoke the function? How would a watch function work here? Would you want it to immediately be invoked?
With serverless-offline, correct me if I'm wrong but it exposes a localhost port which you call manually later? Hence why the watch function is handy because we would update the code to be called.
I feel you could achieve this easily enough with nodemon?
Hmm doesn't invoke local immediately invoke the function? How would a watch function work here? Would you want it to immediately be invoked?
Once immediately, and then every time related sources are modified. It will be a long-running process.
With serverless-offline, correct me if I'm wrong but it exposes a localhost port which you call manually later? Hence why the watch function is handy because we would update the code to be called.
Yes. My functions are largely AppSync resolvers and cron handlers. I would prefer running off predefined event objects and invoke locally, this favors unit tests without setup/teardown of a local web server.
I feel you could achieve this easily enough with nodemon?
Yes, but it makes a different between zeroconf and little-conf. It'd be perfect if custom.esbuild.watch
can be shared with this new feature.
Developers would usually wants to save time by invoking a single function with a few designated inputs.
Since watch mode is already supported for
serverless-offline
, is it possible to also add this for invoke local for quick developments?