Skip to content
Source
Sign inSign up
pingdotgg/t3code
Open History to see the last commit

vite.config.ts

102 lines3.0 KB

1import "vite-plus/test/config";
2import { defineConfig } from "vite-plus";
3​
4export default defineConfig({
5 test: {
6 environment: "node",
7 exclude: [
8 "**/.repos/**",
9 "**/node_modules/**",
10 "**/dist/**",
11 "**/dist-electron/**",
12 "**/.{idea,git,cache,output,temp}/**",
13 ],
14 hookTimeout: 60_000,
15 testTimeout: 60_000,
16 },
17 fmt: {
18 ignorePatterns: [
19 ".reference",
20 ".repos/**",
21 ".plans",
22 ".alchemy",
23 "dist",
24 "dist-electron",
25 "node_modules",
26 "pnpm-lock.yaml",
27 "*.tsbuildinfo",
28 "**/routeTree.gen.ts",
29 "apps/mobile/android/**",
30 "apps/mobile/ios/**",
31 "apps/web/public/mockServiceWorker.js",
32 "apps/web/src/lib/vendor/qrcodegen.ts",
33 "apps/mobile/uniwind-types.d.ts",
34 "*.icon/**",
35 ],
36 sortPackageJson: {},
37 overrides: [
38 {
39 files: [".devcontainer/devcontainer.json"],
40 options: {
41 trailingComma: "none",
42 },
43 },
44 ],
45 },
46 lint: {
47 ignorePatterns: [
48 ".repos",
49 ".repos/**",
50 "dist",
51 "dist-electron",
52 "node_modules",
53 "pnpm-lock.yaml",
54 "*.tsbuildinfo",
55 "**/routeTree.gen.ts",
56 "apps/mobile/android/**",
57 "apps/mobile/ios/**",
58 "apps/mobile/uniwind-types.d.ts",
59 ],
60 plugins: ["eslint", "oxc", "react", "unicorn", "typescript"],
61 jsPlugins: ["./oxlint-plugin-t3code/index.ts"],
62 categories: {
63 correctness: "warn",
64 suspicious: "warn",
65 perf: "warn",
66 },
67 rules: {
68 "unicorn/no-array-sort": "off",
69 "unicorn/consistent-function-scoping": "off",
70 "oxc/no-map-spread": "off",
71 "react-in-jsx-scope": "off",
72 "react-hooks/exhaustive-deps": "off",
73 "eslint/no-shadow": "off",
74 "eslint/no-await-in-loop": "off",
75 "eslint/no-underscore-dangle": "off",
76 "typescript/consistent-return": "off",
77 "typescript/no-base-to-string": "off",
78 "typescript/no-duplicate-type-constituents": "off",
79 "typescript/no-floating-promises": "off",
80 "typescript/no-implied-eval": "off",
81 "typescript/no-meaningless-void-operator": "off",
82 "typescript/no-redundant-type-constituents": "off",
83 "typescript/no-unnecessary-boolean-literal-compare": "off",
84 "typescript/no-unnecessary-type-conversion": "off",
85 "typescript/no-unnecessary-type-arguments": "off",
86 "typescript/no-unnecessary-type-assertion": "off",
87 "typescript/no-unnecessary-type-parameters": "off",
88 "typescript/no-unsafe-type-assertion": "off",
89 "typescript/await-thenable": "off",
90 "typescript/require-array-sort-compare": "off",
91 "typescript/restrict-template-expressions": "off",
92 "typescript/unbound-method": "off",
93 "t3code/no-inline-schema-compile": "warn",
94 "t3code/no-manual-effect-runtime-in-tests": "error",
95 },
96 options: {
97 // Revisit once Oxlint's tsgolint path can integrate with @effect/tsgo diagnostics.
98 typeAware: false,
99 typeCheck: false,
100 },
101 },
102});