Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

vite打包报错 #12

Open
roseliang opened this issue Dec 22, 2021 · 0 comments
Open

vite打包报错 #12

roseliang opened this issue Dec 22, 2021 · 0 comments

Comments

@roseliang
Copy link

roseliang commented Dec 22, 2021

1.vue2项目
2.webpack打包的时候没有问题,换成vite打包出现
node_modules/venn.js/src/layout.js:1:76: error: Could not resolve "../node_modules/fmin/index.js"
1 │ import { nelderMead, bisect, conjugateGradient, zeros, zerosM, norm2 } from '../node_modules/fmin/index.js'
╵ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

node_modules/venn.js/src/diagram.js:6:27: error: Could not resolve "../node_modules/fmin/index.js"
6 │ import { nelderMead } from '../node_modules/fmin/index.js'
╵ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

error when starting dev server:
Error: Build failed with 2 errors:
node_modules/venn.js/src/diagram.js:6:27: error: Could not resolve "../node_modules/fmin/index.js"
node_modules/venn.js/src/layout.js:1:76: error: Could not resolve "../node_modules/fmin/index.js"
at failureErrorWithLog (E:\cms_working\jifen-cms\jifen-cms\node_modules\esbuild\lib\main.js:1493:15)
at E:\cms_working\jifen-cms\jifen-cms\node_modules\esbuild\lib\main.js:1151:28
at runOnEndCallbacks (E:\cms_working\jifen-cms\jifen-cms\node_modules\esbuild\lib\main.js:941:63)
at buildResponseToResult (E:\cms_working\jifen-cms\jifen-cms\node_modules\esbuild\lib\main.js:1149:7)
at E:\cms_working\jifen-cms\jifen-cms\node_modules\esbuild\lib\main.js:1258:14
at E:\cms_working\jifen-cms\jifen-cms\node_modules\esbuild\lib\main.js:629:9
at handleIncomingPacket (E:\cms_working\jifen-cms\jifen-cms\node_modules\esbuild\lib\main.js:726:9)
at Socket.readFromStdout (E:\cms_working\jifen-cms\jifen-cms\node_modules\esbuild\lib\main.js:596:7)
at Socket.Readable.push (node:internal/streams/readable:226:10)
at Pipe.onStreamRead (node:internal/stream_base_commons:190:23)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant