Browse Source

move bundle output to wetter/static/bundle

pull/4/head
Sebastian Speitel 2 years ago
parent
commit
378601de75
  1. 6
      .gitignore
  2. 8
      rollup.config.js

6
.gitignore

@ -5,11 +5,7 @@ wetter/config/db.py
node_modules
# Bundle output
wetter/static/*.js
wetter/static/*.js.map
wetter/static/*.css
wetter/static/*.css.map
wetter/static/images
wetter/static/bundle
# Byte-compiled / optimized / DLL files
__pycache__/

8
rollup.config.js

@ -9,7 +9,7 @@ const production = process.env.NODE_ENV === "production";
const config = {
input: "wetter/static/wetter/js/wetter.js",
output: {
dir: "wetter/static",
dir: "wetter/static/bundle",
format: "iife",
sourcemap: !production
},
@ -18,13 +18,13 @@ const config = {
targets: [
{
src: "node_modules/leaflet/dist/images/*",
dest: "wetter/static/images"
dest: "wetter/static/bundle/images"
}
]
}),
css({
output: "wetter/static/bundle.css",
outFile: "wetter/static/bundle.css",
output: "wetter/static/bundle/bundle.css",
outFile: "wetter/static/bundle/bundle.css",
outputStyle: production ? "compressed" : "expanded",
sourceMap: !production
}),

Loading…
Cancel
Save