有没有与vite-plugin-cesium结合的案例? #698
-
我是用的是vite-plugin-cesium,与cesium结合,在打包时总是会出现路径问题。 |
Beta Was this translation helpful? Give feedback.
Answered by
j524275214
Jan 18, 2025
Replies: 1 comment
-
已解决,使用vite-plugin-cesium-build: |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
j524275214
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
已解决,使用vite-plugin-cesium-build:
import cesiumBuild from 'vite-plugin-cesium-build'
...
plugins: [
createVitePlugins(env, command === 'build'),
command === 'serve' ? cesium() : cesiumBuild({ css: true, from: resolve(__dirname, 'node_modules/cesium/Build/Cesium'), to: 'assets/cesium-package' })
],
...