-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathvite.config.ts
More file actions
72 lines (70 loc) · 1.85 KB
/
Copy pathvite.config.ts
File metadata and controls
72 lines (70 loc) · 1.85 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
import { fileURLToPath } from "node:url";
import { defineConfig } from "vite-plus";
const ignorePatterns = [
"**/dist/**",
"**/node_modules/**",
"**/.nuxt/**",
"examples/basic/dynamic-assets/**",
"packages/nuxt/playground/public-dyn/**",
"packages/nuxt/playground/tsconfig.json",
];
export default defineConfig({
resolve: {
alias: {
"@schemasset/cli": fileURLToPath(new URL("./packages/cli/src/index.ts", import.meta.url)),
"@schemasset/core": fileURLToPath(new URL("./packages/core/src/index.ts", import.meta.url)),
"@schemasset/nuxt": fileURLToPath(new URL("./packages/nuxt/src/index.ts", import.meta.url)),
"@schemasset/schema": fileURLToPath(
new URL("./packages/schema/src/index.ts", import.meta.url),
),
"@schemasset/utils": fileURLToPath(new URL("./packages/utils/src/index.ts", import.meta.url)),
},
},
fmt: {
ignorePatterns,
semi: true,
singleQuote: false,
sortPackageJson: true,
},
lint: {
ignorePatterns,
options: {
typeAware: true,
typeCheck: true,
},
},
test: {
include: ["test/**/*.test.ts"],
},
run: {
tasks: {
check: {
command: "vp check",
},
"check:fix": {
command: "vp check --fix",
},
build: {
command: "vp run --filter './packages/*' build",
},
test: {
command: "vp test",
},
ci: {
command: "vp run check && vp run test && vp run build",
},
"publish:dry": {
command: "vp run ci && pnpm -r publish --dry-run",
},
"publish:all": {
command: "vp run ci && pnpm -r publish --access public",
},
release: {
command: "vp run build && pnpm -r publish --access public --no-git-checks",
},
},
},
staged: {
"*.{js,cjs,mjs,ts,mts,cts,json,jsonc,md,yaml,yml}": "vp check --fix",
},
});