fix(building-rollup): respect user provided full paths

This commit is contained in:
Thomas Allmer
2020-10-24 18:36:15 +02:00
parent 1ed49ff7ac
commit eadbd122c7
2 changed files with 7 additions and 2 deletions

View File

@@ -0,0 +1,5 @@
---
'@open-wc/building-rollup': patch
---
Respect user provided absolute paths

View File

@@ -87,9 +87,9 @@ function createSpaConfig(options) {
globIgnores: ['polyfills/*.js', 'legacy-*.js', 'nomodule-*.js'],
navigateFallback: '/index.html',
// where to output the generated sw
swDest: path.join(process.cwd(), outputDir, 'sw.js'),
swDest: path.join(outputDir, 'sw.js'),
// directory to match patterns against to be precached
globDirectory: path.join(process.cwd(), outputDir),
globDirectory: path.join(outputDir),
// cache any html js and css by default
globPatterns: ['**/*.{html,js,css,webmanifest}'],
skipWaiting: true,