static asset generation restructured and reconfigured.
This commit is contained in:
parent
d91acd36f7
commit
4de4e8dfa1
@ -1,5 +1,2 @@
|
|||||||
|
|
||||||
|
|
||||||
// Site-wide JS imports:
|
|
||||||
import "~/node_modules/bootstrap/js/dist/collapse";
|
import "~/node_modules/bootstrap/js/dist/collapse";
|
||||||
import "simplebar";
|
import "simplebar";
|
2
Props/assets/styles/dependencies.css
Normal file
2
Props/assets/styles/dependencies.css
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
@import "~/node_modules/bootstrap-icons/font/bootstrap-icons.css";
|
||||||
|
@import "~/node_modules/simplebar/dist/simplebar.min.css";
|
@ -116,9 +116,4 @@ body {
|
|||||||
background-color: themer.color-of("background");
|
background-color: themer.color-of("background");
|
||||||
color: themer.color-of("text");
|
color: themer.color-of("text");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Site-wide css imports:
|
|
||||||
@import "~/node_modules/bootstrap-icons/font/bootstrap-icons.css";
|
|
||||||
@import "~/node_modules/simplebar/dist/simplebar.min.css";
|
|
18
Props/package-lock.json
generated
18
Props/package-lock.json
generated
@ -2000,9 +2000,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"css-loader": {
|
"css-loader": {
|
||||||
"version": "6.1.0",
|
"version": "6.2.0",
|
||||||
"resolved": "https://registry.npmjs.org/css-loader/-/css-loader-6.1.0.tgz",
|
"resolved": "https://registry.npmjs.org/css-loader/-/css-loader-6.2.0.tgz",
|
||||||
"integrity": "sha512-AcCb6ire7NgkrxJCtwEDa/y+xxBrPNXYWdlSpXNr+YwW2wTahSowSIxD9cHc9Uvc8Dbq+NQ/NQ6aDvJWik44vg==",
|
"integrity": "sha512-/rvHfYRjIpymZblf49w8jYcRo2y9gj6rV8UroHGmBxKrIyGLokpycyKzp9OkitvqT29ZSpzJ0Ic7SpnJX3sC8g==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"icss-utils": "^5.1.0",
|
"icss-utils": "^5.1.0",
|
||||||
@ -3137,9 +3137,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"postcss": {
|
"postcss": {
|
||||||
"version": "8.3.5",
|
"version": "8.3.6",
|
||||||
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.3.5.tgz",
|
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.3.6.tgz",
|
||||||
"integrity": "sha512-NxTuJocUhYGsMiMFHDUkmjSKT3EdH4/WbGF6GCi1NDGk+vbcUTun4fpbOqaPtD8IIsztA2ilZm2DhYCuyN58gA==",
|
"integrity": "sha512-wG1cc/JhRgdqB6WHEuyLTedf3KIRuD0hG6ldkFEZNCjRxiC+3i6kkWUUbiJQayP28iwG35cEmAbe98585BYV0A==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"colorette": "^1.2.2",
|
"colorette": "^1.2.2",
|
||||||
@ -3583,9 +3583,9 @@
|
|||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"style-loader": {
|
"style-loader": {
|
||||||
"version": "3.1.0",
|
"version": "3.2.1",
|
||||||
"resolved": "https://registry.npmjs.org/style-loader/-/style-loader-3.1.0.tgz",
|
"resolved": "https://registry.npmjs.org/style-loader/-/style-loader-3.2.1.tgz",
|
||||||
"integrity": "sha512-HYVvBMX3RX7zx71pquZV6EcnPN7Deba+zQteSxCLqt3bxYRphmeMr+2mZMrIZjZ7IMa6aOUhNGn8cXGvWMjClw==",
|
"integrity": "sha512-1k9ZosJCRFaRbY6hH49JFlRB0fVSbmnyq1iTPjNxUmGVjBNEmwrrHPenhlp+Lgo51BojHSf6pl2FcqYaN3PfVg==",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"style-value-types": {
|
"style-value-types": {
|
||||||
|
@ -17,12 +17,12 @@
|
|||||||
"babel-eslint": "^10.1.0",
|
"babel-eslint": "^10.1.0",
|
||||||
"babel-loader": "^8.2.2",
|
"babel-loader": "^8.2.2",
|
||||||
"copy-webpack-plugin": "^9.0.1",
|
"copy-webpack-plugin": "^9.0.1",
|
||||||
"css-loader": "^6.1.0",
|
"css-loader": "^6.2.0",
|
||||||
"eslint": "^7.31.0",
|
"eslint": "^7.31.0",
|
||||||
"glob": "^7.1.7",
|
"glob": "^7.1.7",
|
||||||
"sass": "^1.35.2",
|
"sass": "^1.35.2",
|
||||||
"sass-loader": "^12.1.0",
|
"sass-loader": "^12.1.0",
|
||||||
"style-loader": "^3.1.0",
|
"style-loader": "^3.2.1",
|
||||||
"webpack": "^5.45.1",
|
"webpack": "^5.45.1",
|
||||||
"webpack-cli": "^4.7.2",
|
"webpack-cli": "^4.7.2",
|
||||||
"webpack-merge": "^5.8.0"
|
"webpack-merge": "^5.8.0"
|
||||||
@ -35,4 +35,4 @@
|
|||||||
"popmotion": "^9.4.0",
|
"popmotion": "^9.4.0",
|
||||||
"simplebar": "^5.3.5"
|
"simplebar": "^5.3.5"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -9,22 +9,15 @@ let config = {
|
|||||||
obj[name] = elem;
|
obj[name] = elem;
|
||||||
return obj;
|
return obj;
|
||||||
}, {
|
}, {
|
||||||
site: [path.resolve("./assets/js/main.js"), path.resolve("./assets/scss/main.scss")],
|
site: [path.resolve("./assets/js/site-wide.js"), path.resolve("./assets/styles/site-wide.scss"), path.resolve("./assets/styles/dependencies.css")],
|
||||||
}),
|
}),
|
||||||
output: {
|
output: {
|
||||||
filename: "[name].js",
|
filename: "[name].js",
|
||||||
path: path.resolve("./wwwroot/js"),
|
path: path.resolve("./wwwroot/js"),
|
||||||
|
clean: true,
|
||||||
},
|
},
|
||||||
module: {
|
module: {
|
||||||
rules: [
|
rules: [
|
||||||
{
|
|
||||||
test: /\.s[ac]ss$/i,
|
|
||||||
use: [
|
|
||||||
"style-loader",
|
|
||||||
"css-loader",
|
|
||||||
"sass-loader",
|
|
||||||
],
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
test: /\.m?js$/,
|
test: /\.m?js$/,
|
||||||
exclude: /(node_modules|bower_components)/,
|
exclude: /(node_modules|bower_components)/,
|
||||||
@ -36,10 +29,26 @@ let config = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
test: /\.s[ac]ss$/i,
|
||||||
|
use: [
|
||||||
|
"style-loader",
|
||||||
|
"css-loader",
|
||||||
|
"sass-loader",
|
||||||
|
],
|
||||||
|
},
|
||||||
|
{
|
||||||
|
test: /\.css$/i,
|
||||||
|
use: ["style-loader", "css-loader"],
|
||||||
|
},
|
||||||
{
|
{
|
||||||
test: /\.(png|svg|jpg|jpeg|gif)$/i,
|
test: /\.(png|svg|jpg|jpeg|gif)$/i,
|
||||||
type: "asset/resource",
|
type: "asset/resource",
|
||||||
}
|
},
|
||||||
|
{
|
||||||
|
test: /\.(woff|woff2|eot|ttf|otf)$/i,
|
||||||
|
type: "asset/resource",
|
||||||
|
},
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
resolve: {
|
resolve: {
|
||||||
|
@ -3,7 +3,18 @@ const common = require("./webpack.common");
|
|||||||
|
|
||||||
let config = {
|
let config = {
|
||||||
mode: "development",
|
mode: "development",
|
||||||
devtool: "eval-source-map",
|
devtool: "eval-cheap-module-source-map",
|
||||||
|
output: {
|
||||||
|
pathinfo: false,
|
||||||
|
},
|
||||||
|
optimization: {
|
||||||
|
removeAvailableModules: false,
|
||||||
|
removeEmptyChunks: false,
|
||||||
|
mergeDuplicateChunks: false,
|
||||||
|
providedExports: false,
|
||||||
|
splitChunks: false,
|
||||||
|
innerGraph: false,
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
module.exports = merge(common, config);
|
module.exports = merge(common, config);
|
||||||
|
@ -4,6 +4,11 @@ const common = require("./webpack.common");
|
|||||||
let config = {
|
let config = {
|
||||||
mode: "production",
|
mode: "production",
|
||||||
devtool: "nosources-source-map",
|
devtool: "nosources-source-map",
|
||||||
|
optimization: {
|
||||||
|
mangleExports: "size",
|
||||||
|
moduleIds: "size",
|
||||||
|
chunkIds: "size",
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
module.exports = merge(common, config);
|
module.exports = merge(common, config);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user