flora is a fast and secure runtime that lets you write discord bots for your servers, with a rich TypeScript SDK, without worrying about running infrastructure. [mirror]
1import { defineConfig } from 'vite-plus'
2
3const ignorePatterns = [
4 '**/node_modules',
5 '**/*-lock.json',
6 'pnpm-lock.yaml',
7 '**/bun.lock',
8 '**/submodules/**',
9 '**/dist',
10 '**/trash',
11 '**/target',
12 '**/refs/**',
13 'pnpm-lock.yaml'
14]
15
16export default defineConfig({
17 run: {
18 cache: {
19 scripts: true,
20 tasks: true
21 },
22 tasks: {
23 build: {
24 command: 'vp run -r build',
25 env: ['NODE_ENV', 'VITE_*']
26 },
27 'apps:build': {
28 command: [
29 'vp run',
30 '--filter "@flora-internal/build-service"',
31 '--filter "@flora-internal/frontend"',
32 '--filter "@flora-internal/uwu.network"',
33 '--filter "@flora-internal/www"',
34 'build'
35 ].join(' '),
36 dependsOn: ['@uwu/flora-api-client#build', '@uwu/flora-cli#build', '@uwu/flora-sdk#build'],
37 env: ['NODE_ENV', 'VITE_*']
38 },
39 test: {
40 command: 'vp run -r test',
41 env: ['NODE_ENV', 'VITE_*']
42 },
43 typecheck: {
44 command: 'vp run -r typecheck'
45 },
46 lint: {
47 command: 'vp run -r lint'
48 }
49 }
50 },
51 staged: {
52 '*': 'vp check --fix'
53 },
54 fmt: {
55 quoteProps: 'preserve',
56 printWidth: 100,
57 singleQuote: true,
58 semi: false,
59 trailingComma: 'none',
60 tabWidth: 2,
61 ignorePatterns,
62 jsxSingleQuote: true
63 },
64 /**
65 lint: {
66 "plugins": [
67 "eslint",
68 "typescript",
69 "unicorn",
70 "react",
71 "react-perf",
72 "oxc",
73 "jsx-a11y",
74 "promise"
75 ],
76 "categories": {},
77 "rules": {},
78 "options": {
79 "typeAware": true,
80 "typeCheck": true
81 },
82 "settings": {
83 "jsx-a11y": {
84 "components": {},
85 "attributes": {}
86 },
87 "next": {
88 "rootDir": []
89 },
90 "react": {
91 "formComponents": [],
92 "linkComponents": [],
93 "componentWrapperFunctions": []
94 },
95 "jsdoc": {
96 "ignorePrivate": false,
97 "ignoreInternal": false,
98 "ignoreReplacesDocs": true,
99 "overrideReplacesDocs": true,
100 "augmentsExtendsReplacesDocs": false,
101 "implementsReplacesDocs": false,
102 "exemptDestructuredRootsFromChecks": false,
103 "tagNamePreference": {}
104 },
105 "vitest": {
106 "typecheck": true
107 }
108 },
109 "env": {
110 "builtin": true
111 },
112 "globals": {},
113 ignorePatterns,
114 },
115 **/
116 test: {}
117})