Config updates to add bundles to build folder so that index.html can be un-gitignored

This commit is contained in:
Conor Mack 2020-02-03 18:48:49 +00:00
parent f4402d9092
commit 0d1ec13f4d
3 changed files with 21 additions and 3 deletions

View File

@ -3,4 +3,4 @@ node_modules
yarn.lock
package-lock.json
dist/index.js
public/*
public/build

View File

@ -0,0 +1,18 @@
<!doctype html>
<html>
<head>
<meta charset='utf8'>
<meta name='viewport' content='width=device-width'>
<title>Svelte app</title>
<link href="https://fonts.googleapis.com/icon?family=Material+Icons"
rel="stylesheet">
<link rel='icon' type='image/png' href='/favicon.png'>
<link rel='stylesheet' href='/build/bundle.css'>
</head>
<body>
<script src='/build/bundle.js'></script>
</body>
</html>

View File

@ -91,7 +91,7 @@ export default {
sourcemap: true,
format: "iife",
name: "app",
file: "public/bundle.js",
file: "public/build/bundle.js",
globals: {
crypto: "crypto"
}
@ -104,7 +104,7 @@ export default {
// we'll extract any component CSS out into
// a separate file — better for performance
css: css => {
css.write("public/bundle.css");
css.write("public/build/bundle.css");
},
hydratable: true