2020-08-30 02:19:46 +02:00
|
|
|
const path = require("path");
|
|
|
|
const CopyPlugin = require("copy-webpack-plugin");
|
|
|
|
|
|
|
|
module.exports = {
|
2020-09-25 01:11:04 +02:00
|
|
|
lintOnSave: false,
|
2020-08-30 02:19:46 +02:00
|
|
|
chainWebpack: config => {
|
2021-05-24 19:53:15 +02:00
|
|
|
config.module
|
|
|
|
.rule('vue')
|
|
|
|
.use('vue-loader')
|
|
|
|
.tap(options => {
|
|
|
|
const compilerOptions = {
|
|
|
|
}
|
|
|
|
compilerOptions.isCustomElement = (tag) => tag.startsWith('sl-');
|
|
|
|
options.compilerOptions = compilerOptions;
|
|
|
|
return options
|
|
|
|
});
|
2020-08-30 02:19:46 +02:00
|
|
|
config.plugin("copy-icons").use(CopyPlugin, [
|
|
|
|
[
|
|
|
|
{
|
|
|
|
from: path.resolve(
|
|
|
|
__dirname,
|
2021-04-04 17:54:46 +02:00
|
|
|
"node_modules/@shoelace-style/shoelace/dist/assets/icons"
|
2020-08-30 02:19:46 +02:00
|
|
|
),
|
|
|
|
to: path.resolve(__dirname, "dist/assets/icons")
|
|
|
|
}
|
|
|
|
]
|
|
|
|
]);
|
|
|
|
config.devServer.proxy({
|
|
|
|
"/api": { target: "http://localhost:8093" }
|
|
|
|
});
|
|
|
|
}
|
|
|
|
};
|