wagmi: [bug] build with Nextjs, error 'Uncaught SyntaxError: Unexpected template string' occurs
Is there an existing issue for this?
- I have searched the existing issues
Package Version
0.2.15
Current Behavior
Demo repo:
https://github.com/liran319/next-wagmi-demo
I have install wagmi@0.2.15 into my project with Nextjs, it works well when start project with ‘yarn dev’.
But Uncaught SyntaxError: Unexpected template string occurs when run ‘yarn build && yarn start’.

It seems that only occurs on production mode.And there is no stack to debug. Could you please have a check?
Expected Behavior
Both development and production mode work well.
Steps To Reproduce
- Clone the repo
https://github.com/liran319/next-wagmi-demo, and enter that folder; - Run
yarnto install deps; - Run ‘yarn build && yarn start’
- check console, found ‘Uncaught SyntaxError: Unexpected template string’, and button doesn’t work
Link to Minimal Reproducible Example (CodeSandbox, StackBlitz, etc.)
No response
Anything else?
No response
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 16 (8 by maintainers)
OH yes, it is! It works! But I think there is some where can be optimized and fixed on
wagmi.Thanks you very much!