From 56cca63b2dbbc2d6d80508bd7c582a7109b8dae7 Mon Sep 17 00:00:00 2001 From: Robert Marshall Date: Sat, 20 Apr 2019 13:00:43 +0100 Subject: [PATCH] Add bundling and minification --- .gitignore | 6 +++++- Website/Website.csproj | 1 + Website/bundleconfig.json | 19 +++++++++++++++++++ 3 files changed, 25 insertions(+), 1 deletion(-) create mode 100644 Website/bundleconfig.json diff --git a/.gitignore b/.gitignore index b21a1d3..8e16b98 100644 --- a/.gitignore +++ b/.gitignore @@ -38,4 +38,8 @@ msbuild.wrn #lcov files -lcov.info \ No newline at end of file +lcov.info + +#minified files +*.min.css +*.min.js \ No newline at end of file diff --git a/Website/Website.csproj b/Website/Website.csproj index 3f3202f..28f3351 100644 --- a/Website/Website.csproj +++ b/Website/Website.csproj @@ -7,6 +7,7 @@ + diff --git a/Website/bundleconfig.json b/Website/bundleconfig.json new file mode 100644 index 0000000..83cc504 --- /dev/null +++ b/Website/bundleconfig.json @@ -0,0 +1,19 @@ +[ + { + "outputFileName": "wwwroot/css/site.min.css", + "inputFiles": [ + "wwwroot/css/site.css" + ] + }, + { + "outputFileName": "wwwroot/js/site.min.js", + "inputFiles": [ + "wwwroot/js/site.js" + ], + "minify": { + "enabled": true, + "renameLocals": true + }, + "sourceMap": false + } +] \ No newline at end of file