Switch from svite to vite + vite-plugin-svelte. (#962)

Use cross-env to set environment variables platform independently in scripts.
This commit is contained in:
brunnerh 2021-12-31 19:11:48 +01:00 committed by GitHub
commit 1bc04c5b42
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 250 additions and 2044 deletions

View file

@ -2,20 +2,22 @@
"private": true,
"scripts": {
"dev": "run-p dev:*",
"dev:routify": "NODE_ENV=development routify run",
"dev:svite": "svite",
"dev:routify": "cross-env NODE_ENV=development routify run",
"dev:svite": "vite dev",
"build": "run-s build:*",
"build:routify": "routify run -b",
"build:svite": "svite build"
"build:svite": "vite build"
},
"devDependencies": {
"@sveltech/routify": "^1.9.9",
"@sveltejs/vite-plugin-svelte": "^1.0.0-next.33",
"autoprefixer": "^10.2.3",
"carbon-components": "10.48.0",
"carbon-components-10.47": "npm:carbon-components@10.47",
"carbon-components-svelte": "../",
"carbon-icons-svelte": "^10.38.0",
"clipboard-copy": "^4.0.1",
"cross-env": "^7.0.3",
"mdsvex": "^0.8.8",
"npm-run-all": "^4.1.5",
"postcss": "^8.2.4",
@ -25,10 +27,10 @@
"prismjs": "^1.21.0",
"remark-slug": "^6.0.0",
"sass": "^1.42.1",
"svelte": "3.29.0",
"svelte": "^3.44.3",
"svelte-hmr": "0.11.1",
"svelte-preprocess": "^4.3.2",
"svite": "0.7.2"
"vite": "^2.7.10"
},
"routify": {
"routifyDir": ".routify",

View file

@ -1,6 +1,10 @@
module.exports = {
import { defineConfig } from "vite";
import { svelte } from "@sveltejs/vite-plugin-svelte";
export default defineConfig({
plugins: [svelte()],
optimizeDeps: {
include: ["clipboard-copy", "flatpickr/dist/plugins/rangePlugin"],
exclude: ["@sveltech/routify"],
},
};
});

File diff suppressed because it is too large Load diff