1. Vue module augmentation (src/shims-vue.d.ts) *Added ComponentCustomProperties so this.$store is typed as Store<RootState> in components. *Extended Window for $ and jQuery so the jQuery global assignment type-checks. 2. Convert main.js to main.ts *Renamed main.js to main.ts. *Removed the vue.config.js entry override so the Vue CLI TypeScript plugin uses main.ts. *Updated jest.config.js to exclude main.ts from coverage. *Adjusted the error handler to use unknown for err and vm to match Vue’s types. *Added as unknown to the jQuery require for type safety.
28 lines
878 B
JavaScript
28 lines
878 B
JavaScript
const webpack = require('webpack');
|
|
const { environmentVariablesWithDefaults } = require('./environment-variables.js');
|
|
|
|
module.exports = {
|
|
outputDir: "dist/fmg",
|
|
publicPath: "/fmg",
|
|
css: {
|
|
loaderOptions: {
|
|
sass: {
|
|
// Load Order Matters!!!
|
|
// Note: only include functions, variables and mixins here
|
|
prependData: `
|
|
@import "./node_modules/bootstrap/scss/functions";
|
|
@import "@/styles/ux-variables.scss";
|
|
@import "./node_modules/bootstrap/scss/variables";
|
|
@import "./node_modules/bootstrap/scss/mixins";
|
|
@import "@/styles/mixins/customMixins";
|
|
`,
|
|
},
|
|
},
|
|
},
|
|
configureWebpack: {
|
|
devtool: "source-map",
|
|
plugins: [
|
|
new webpack.EnvironmentPlugin(environmentVariablesWithDefaults),
|
|
],
|
|
},
|
|
};
|