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
Create separate temporal packages for activities and workflows
Create temporal client as part of an API route apps/web and import one of the workflows from the workflows package
Call the temporal workflow from the NextJS client API route
Current vs. Expected behavior
SWC minifies Temporal workflow name and it cannot be resolved against the actual workflow name within the Temporal environment. The only fix for this is to set swcMinify: false in next.config.js, and update manual webpack config with Terser to set keep_fnames: true.
Provide environment information
Operating System:
Platform: darwin
Arch: arm64
Version: Darwin Kernel Version 24.2.0: Fri Dec 6 19:01:59 PST 2024; root:xnu-11215.61.5~2/RELEASE_ARM64_T6000
Available memory (MB): 16384
Available CPU cores: 8
Binaries:
Node: 20.15.1
npm: 10.7.0
Yarn: 1.22.19
pnpm: 9.12.1
Relevant Packages:
next: 14.2.18 // An outdated version detected (latest is 15.1.3), upgrade is highly recommended!
eslint-config-next: 14.2.5
react: 18.3.1
react-dom: 18.3.1
typescript: 5.5.4
Next.js Config:
output: N/A
Which area(s) are affected? (Select all that apply)
SWC
Which stage(s) are affected? (Select all that apply)
next build (local), next start (local), Vercel (Deployed)
Additional context
Tested this against next 14 and 15 builds
The text was updated successfully, but these errors were encountered:
Link to the code that reproduces this issue
https://github.com/njoshi22
To Reproduce
Current vs. Expected behavior
SWC minifies Temporal workflow name and it cannot be resolved against the actual workflow name within the Temporal environment. The only fix for this is to set
swcMinify: false
in next.config.js, and update manual webpack config with Terser to setkeep_fnames: true
.Provide environment information
Which area(s) are affected? (Select all that apply)
SWC
Which stage(s) are affected? (Select all that apply)
next build (local), next start (local), Vercel (Deployed)
Additional context
Tested this against next 14 and 15 builds
The text was updated successfully, but these errors were encountered: