-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvue.config.js
57 lines (46 loc) · 1 KB
/
vue.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
const fs = require("fs");
const htmlCommonTemplate = "./app/html/CommonTemplate.html";
if (process.env.SOURCE_EDITOR_DIR)
process.env.VUE_APP_USE_SOURCE_EDITOR = true;
if (fs.existsSync("./demo.local.ly"))
process.env.VUE_APP_DEMO_SCORE = fs.readFileSync("./demo.local.ly", "utf8");
module.exports = {
publicPath: "./",
outputDir: "dist",
pages: {
index: {
entry: "./app/index.ts",
template: htmlCommonTemplate,
title: "Lotus",
},
},
chainWebpack: config => {
// text file loader
config.module
.rule("raw-text")
.test(/\.jison$/)
.use("url-loader")
.loader("url-loader");
config.externals({
musicWidgets: "@k-l-lambda/music-widgets",
});
/*// ignore third-party packed js
config.module
.rule("js")
.exclude
.add(/.*\.min\.js$/)
.end();*/
},
css: {
extract: false,
},
devServer: {
//proxy: `http://localhost:${process.env.PORT}`,
proxy: {
"/": {
target: `http://localhost:${process.env.PORT}`,
},
},
https: !!process.env.HTTPS,
},
};