Plasmic Tanstack

I am trying to use Plasmic TanStack with Plasmic Codegen.

I had installed using

  • npx create-plasmic-app@latest
  • language → Typescript
  • framework → TanStack Start

I had configure custome app host to http://localhost:3000/plasmic-host

Once I goto http://localhost:3000 I got the following error:

An error occured while server rendering /index.html: [vite] Named export ‘StrictProps’ not found. The requested module ‘@plasmicapp/react-web’ is a CommonJS module, which may not support all module.exports as named exports. CommonJS modules can always be imported via the default export, for example using: import pkg from ‘@plasmicapp/react-web’; const {Flex, MultiChoiceArg, SingleBooleanChoiceArg, SingleChoiceArg, StrictProps} = pkg;

SyntaxError: [vite] Named export ‘StrictProps’ not found. The requested module ‘@plasmicapp/react-web’ is a CommonJS module, which may not support all module.exports as named exports. CommonJS modules can always be imported via the default export, for example using: import pkg from ‘@plasmicapp/react-web’; const {Flex, MultiChoiceArg, SingleBooleanChoiceArg, SingleChoiceArg, StrictProps} = pkg; at analyzeImportedModDifference (file:///D:/1PROJECTS/AUTH/CODES/plasmictanstack/node_modules/vite/dist/node/module-runner.js:532:11) at ModuleRunner.processImport (file:///D:/1PROJECTS/AUTH/CODES/plasmictanstack/node_modules/vite/dist/node/module-runner.js:1142:56) at ModuleRunner.cachedRequest (file:///D:/1PROJECTS/AUTH/CODES/plasmictanstack/node_modules/vite/dist/node/module-runner.js:1178:21

Click outside, press Esc key, or fix the code to dismiss.
You can also disable this overlay by setting server.hmr.overlay to false in vite.config.ts.

Please advise when free. This is not urgent.

Thank you for your kind attention.

Thank you for reporting. We were able to reproduce this issue and will be looking into it.

@mouthains We are pushing a fix for the Tanstack Start integration, but in the meantime, please set verbatimModuleSyntax to false in your tanstack app’s tsconfig.json to unblock yourself.

1 Like