-
Notifications
You must be signed in to change notification settings - Fork 20
/
Copy pathvue.config.js
53 lines (52 loc) · 1.71 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
const path = require("path");
const pkg = require("./package.json");
const { ProvidePlugin } = require("webpack");
const p = require('path');
module.exports = {
pages: {
index: {
entry: path.join("src", "main.ts"),
title: pkg.app.name,
},
},
configureWebpack: (config) => {
config.resolve.fallback = {
...config.resolve.fallback,
crypto: false,
stream: false,
assert: false,
os: false,
https: false,
http: false,
zlib: false,
url: false,
};
config.resolve.alias = {
...config.resolve.alias,
'bn.js': p.join(__dirname, 'node_modules/bn.js/lib/bn.js'),
}
config.plugins.push(new ProvidePlugin({Buffer: ["buffer", "Buffer"]}));
config.plugins.push(new ProvidePlugin({process: ["process/browser"]}));
// config.optimization.splitChunks = {
// ...config.optimization.splitChunks,
// minSize: 10000,
// maxSize: 250000,
// }
},
pwa: {
name: "Torus Wallet",
themeColor: "#70a3ff",
msTileColor: "#000000",
appleMobileWebAppCapable: "yes",
appleMobileWebAppStatusBarStyle: "black",
iconPaths: {
faviconSVG: "img/icons/favicon.svg",
favicon32: "img/icons/favicon-32x32.png",
favicon16: "img/icons/favicon-16x16.png",
appleTouchIcon: "img/icons/apple-touch-icon-152x152.png",
maskIcon: "img/icons/safari-pinned-tab.svg",
msTileImage: "img/icons/msapplication-icon-144x144.png",
},
},
productionSourceMap: false
};