2082001ff8
* Initial tests set up This adds tests using uvu (we can switch if people want) and restructures things a bit so that it's easier to test. Like in snowpack you set up a little project. In our tests you can say: ```js const result = await runtime.load('/blog/hello-world') ``` And analyze the result. I included a `test-helpers.js` which has a function that will turn HTML into a cheerio instance, for inspecting the result HTML. * Bring snowpack example in * Formatting
31 lines
667 B
JavaScript
31 lines
667 B
JavaScript
/** @type {import("snowpack").SnowpackUserConfig } */
|
|
module.exports = {
|
|
mount: {
|
|
public: '/',
|
|
//src: '/_dist_',
|
|
},
|
|
plugins: [
|
|
[
|
|
'@snowpack/plugin-sass', { compilerOptions: { style: 'compressed' } },
|
|
],
|
|
'@snowpack/plugin-svelte',
|
|
'@snowpack/plugin-vue'
|
|
],
|
|
packageOptions: {
|
|
// Blocked by CSS asset support
|
|
// source: 'remote',
|
|
// types: true,
|
|
},
|
|
devOptions: {
|
|
// Eleventy updates multiple files at once, so add a 1000ms delay before we trigger a browser update
|
|
hmrDelay: 1000,
|
|
},
|
|
buildOptions: {
|
|
out: '_site',
|
|
},
|
|
optimize: {
|
|
bundle: true,
|
|
minify: true,
|
|
target: 'es2018',
|
|
},
|
|
};
|