You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are various issues related to how to share functions between bundled workflow code and activity code.
Your recommended content
One example is how to log from such functions.
I have a number of modules that I want to use inside and outside a workflow. I would like these modules to use the logger sink when inside a workflow context, but use its current logger implementation when outside a workflow (without changing all these source files).
importmyLoggerfrom'~/myLogger';// I wanna use this function in both contexts and have it "just work"functionthisIsPureExceptForTheLoggerStatement(){// ...myLogger.log(`Some debug information`);// ...}
Answer: ignore the real logger module in the bundleOptions, something like this (untested):
* working example for temporalio/documentation#1860
* package.json and README cleanup
* create CI task for new samples
* quick readme fix
* fix copy shared files with new samples and github CI
Brief description
There are various issues related to how to share functions between bundled workflow code and activity code.
Your recommended content
One example is how to log from such functions.
Answer: ignore the real logger module in the bundleOptions, something like this (untested):
The text was updated successfully, but these errors were encountered: