1 Star 0 Fork 1

网络虫/vue2-cesium-screen

forked from Fumk/vue2-cesium-screen 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
vue.config.js 1.58 KB
一键复制 编辑 原始数据 按行查看 历史
付民康 提交于 2023-07-12 14:24 . first commit
const { defineConfig } = require("@vue/cli-service");
const path = require("path");
const webpack = require("webpack");
const CopyWebpackPlugin = require("copy-webpack-plugin");
const NodePolyfillPlugin = require("node-polyfill-webpack-plugin");
function resolve(dir) {
return path.join(__dirname, dir);
}
module.exports = defineConfig({
transpileDependencies: true,
lintOnSave: false,
configureWebpack: {
name: "vue-cesium",
resolve: {
alias: {
"@": resolve("src"),
},
},
plugins: [
new NodePolyfillPlugin(),
new CopyWebpackPlugin({
patterns: [
{
from: "node_modules/cesium/Build/Cesium/Workers",
to: "cesium/Workers",
},
{
from: "node_modules/cesium/Build/Cesium/ThirdParty",
to: "cesium/ThirdParty",
},
{
from: "node_modules/cesium/Build/Cesium/Assets",
to: "cesium/Assets",
},
{
from: "node_modules/cesium/Build/Cesium/Widgets",
to: "cesium/Widgets",
},
],
}),
new webpack.DefinePlugin({
// Define relative base path in cesium for loading assets
CESIUM_BASE_URL: JSON.stringify("./cesium"),
}),
],
module: {
rules: [
{
test: /.js$/,
include: /(cesium)/,
use: {
loader: "@open-wc/webpack-import-meta-loader",
},
},
],
},
},
pluginOptions: {
"style-resources-loader": {
preProcessor: "less",
patterns: [],
},
},
});
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/wangluochong/vue2-cesium-screen.git
git@gitee.com:wangluochong/vue2-cesium-screen.git
wangluochong
vue2-cesium-screen
vue2-cesium-screen
master

搜索帮助