async loading of css files
import loadCss from '@carv/cdn-css-loader'
const element = await loadCss('./url/to/style.css')Runs the app in the development mode. Open http://localhost:8080 to view it in the browser.
The page will reload if you make edits.
Two sub scripts will came in handy from time to time:
npm start test.watch: re-run tests on changenpm start test.coverage: creates a coverage report atcoverage/lcov-report/index.html
Formats all sources using prettier.
- Update changelog
npm run formatnpm test- git commit -a -m "chore: prepare release`
- npm version [<newversion> | major | minor | patch] -m "chore: release"
Put all your source code including your test files here. Test files are matched using the following regexp:
src/**/__tests__/*.{js,jsx,ts,tsx}: matches every file within a__tests__directory but not in child directoriessrc/**/*.{spec,test}.{js,jsx,ts,tsx}: matches*.test.jsand*.spec.jsfiles; some for the other extensions
This directory is used by snowpack on npm start to render a preview of your code.
Modify src/__preview__/app.svelte to match your needs.