-
-
Notifications
You must be signed in to change notification settings - Fork 235
Closed
Labels
Description
Describe the bug
Testing the main branch (including vitejs/vite#8546) since vite@3-alpha10 doesn't work for production builds of Ladle.
- checkout https://github.com/tajo/ladle/tree/test-vite
- assumes it's next to built
viterepo (using pnpm overrides) - go to
ladle/packages/example pnpm ladle build
Log:
➜ example git:(test-vite) y ladle build
yarn run v1.22.18
$ /Users/vojtech/Projects/ladle/packages/example/node_modules/.bin/ladle build
vite v3.0.0-alpha.10 building for production...
transforming (50) ../../../example/node_modules/.vite/deps_build/react-dom_client.js'jsx' is not exported by '../../node_modules/.pnpm/react@18.1.0/node_modules/react/jsx-runtime.js'
'jsxs' is not exported by '../../node_modules/.pnpm/react@18.1.0/node_modules/react/jsx-runtime.js'
'Fragment' is not exported by '../../node_modules/.pnpm/react@18.1.0/node_modules/react/jsx-runtime.js'
✓ 64 modules transformed.
If you try to run the server with build folder you get some generic error:
Uncaught ReferenceError: module is not defined
at index.6fff39be.js:9:2024
(Is there a simple way how I could do this repro with StackBlitz?)
Reproduction
https://github.com/tajo/ladle/tree/test-vite
System Info
System:
OS: macOS 12.4
CPU: (10) arm64 Apple M1 Max
Memory: 23.87 GB / 64.00 GB
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 16.15.0 - ~/.nvm/versions/node/v16.15.0/bin/node
Yarn: 1.22.18 - ~/.nvm/versions/node/v16.15.0/bin/yarn
npm: 8.5.5 - ~/.nvm/versions/node/v16.15.0/bin/npm
Browsers:
Chrome: 102.0.5005.61
Firefox: 101.0
Safari: 15.5Used Package Manager
pnpm
Logs
No response
Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- Make sure this is a Vite issue and not a framework-specific issue. For example, if it's a Vue SFC related bug, it should likely be reported to https://github.com/vuejs/core instead.
- Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
- The provided reproduction is a minimal reproducible example of the bug.
Reactions are currently unavailable