Skip to content

Commit b544e07

Browse files
committed
chore: Add new configuration files and enhance linting integration
This commit introduces several new configuration files, including `.editorconfig`, `.oxlintrc.json`, and updates to existing files like `package.json` and `pnpm-lock.yaml`. It also enhances the linting integration across the codebase, ensuring consistent code quality and adherence to standards. Additionally, the README is updated to reflect these changes, providing clearer guidance for developers on the new configurations.
1 parent 3296936 commit b544e07

File tree

231 files changed

+13157
-13136
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

231 files changed

+13157
-13136
lines changed

.editorconfig

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# EditorConfig helps maintain consistent coding styles across editors
2+
# https://editorconfig.org
3+
4+
root = true
5+
6+
# Universal settings
7+
[*]
8+
charset = utf-8
9+
end_of_line = lf
10+
insert_final_newline = true
11+
trim_trailing_whitespace = true
12+
13+
# TypeScript, JavaScript, React
14+
[*.{ts,tsx,js,jsx,mjs,cjs}]
15+
indent_style = space
16+
indent_size = 2
17+
18+
# Solidity
19+
[*.sol]
20+
indent_style = space
21+
indent_size = 4
22+
23+
# JSON, YAML
24+
[*.{json,yml,yaml}]
25+
indent_style = space
26+
indent_size = 2
27+
28+
# Markdown
29+
[*.md]
30+
trim_trailing_whitespace = false
31+
indent_style = space
32+
indent_size = 2
33+
34+
# Shell scripts
35+
[*.sh]
36+
indent_style = space
37+
indent_size = 2
38+
39+
# Makefiles
40+
[Makefile]
41+
indent_style = tab
42+

.oxlintrc.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"rules": {
3+
"typescript/no-unused-vars": "error",
4+
"react/react-hooks-exhaustive-deps": "error",
5+
"react/rules-of-hooks": "error",
6+
"react/jsx-no-unescaped-entities": "error"
7+
},
8+
"ignorePatterns": [
9+
"e2e/playwright-report/**",
10+
"e2e/test-results/**"
11+
]
12+
}
13+

README.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ Decentralized funding pools with smart access control. Create shared ETH/ERC20 p
66

77
**Manual Install**: Node.js 18+, Git
88
**Auto-Install**: pnpm, Foundry *(installed automatically)*
9-
**System**: 4GB+ RAM, 2GB storage
9+
**System**: 4GB+ RAM, 2GB storage
10+
**Editor**: VS Code or Cursor *(recommended for inline linting)*
1011

1112
> ⚠️ **Note on Submodules**: This repository uses git submodules for Foundry dependencies. If you encounter SSH errors during `pnpm install`, see the [Submodule/Foundry Setup Issues](#submodulefoundry-setup-issues) section for quick HTTPS workaround or SSH setup instructions.
1213
@@ -37,6 +38,17 @@ Open http://localhost:3000 and explore 4 pre-seeded demo jars with Cookie Monste
3738
>
3839
> **💡 Note**: If you don't have pnpm installed, Option 1 installs it for you. If you already have pnpm, use Option 2.
3940
41+
### 🎨 Editor Setup (Recommended)
42+
43+
For the best development experience with **inline linting errors** and **auto-fix on save**:
44+
45+
1. Open workspace in VS Code or Cursor
46+
2. Install recommended extensions when prompted (ESLint, Prettier, Solidity)
47+
3. Reload window to activate linting
48+
4. Errors now appear inline as you code!
49+
50+
See [docs/DEVELOPMENT.md](docs/DEVELOPMENT.md#editor-setup) for details.
51+
4052
## 💻 Development
4153

4254
```bash

biome.json

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
{
2+
"$schema": "https://biomejs.dev/schemas/2.2.5/schema.json",
3+
"vcs": {
4+
"enabled": true,
5+
"clientKind": "git",
6+
"useIgnoreFile": true
7+
},
8+
"files": {
9+
"ignoreUnknown": false,
10+
"includes": ["client/**/*", "e2e/**/*.ts", "client/**/*.css"]
11+
},
12+
"css": {
13+
"formatter": {
14+
"enabled": true,
15+
"quoteStyle": "double"
16+
},
17+
"linter": {
18+
"enabled": true
19+
}
20+
},
21+
"formatter": {
22+
"enabled": true,
23+
"formatWithErrors": false,
24+
"indentStyle": "space",
25+
"indentWidth": 2,
26+
"lineWidth": 80,
27+
"lineEnding": "lf"
28+
},
29+
"linter": {
30+
"enabled": true,
31+
"rules": {
32+
"recommended": true,
33+
"correctness": {
34+
"noUnusedVariables": "error",
35+
"useExhaustiveDependencies": "error",
36+
"useHookAtTopLevel": "error"
37+
},
38+
"style": {
39+
"useConst": "error"
40+
},
41+
"suspicious": {
42+
"noExplicitAny": "warn",
43+
"noUnknownAtRules": "off"
44+
},
45+
"a11y": {
46+
"recommended": true
47+
}
48+
}
49+
},
50+
"javascript": {
51+
"formatter": {
52+
"quoteStyle": "single",
53+
"jsxQuoteStyle": "double",
54+
"trailingCommas": "es5",
55+
"semicolons": "always",
56+
"arrowParentheses": "always",
57+
"bracketSpacing": true,
58+
"quoteProperties": "asNeeded"
59+
}
60+
},
61+
"json": {
62+
"formatter": {
63+
"enabled": true
64+
}
65+
},
66+
"overrides": [
67+
{
68+
"includes": [
69+
"**/__tests__/**",
70+
"**/*.test.ts",
71+
"**/*.test.tsx",
72+
"**/*.spec.ts",
73+
"e2e/**/*.ts"
74+
],
75+
"linter": {
76+
"rules": {
77+
"suspicious": {
78+
"noExplicitAny": "off"
79+
}
80+
}
81+
}
82+
}
83+
]
84+
}

client/.eslintrc.json

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,15 @@
11
{
22
"extends": ["next/core-web-vitals"],
3+
"parserOptions": {
4+
"ecmaVersion": "latest",
5+
"sourceType": "module"
6+
},
37
"rules": {
4-
"no-unused-vars": "warn",
8+
"no-unused-vars": "error",
59
"no-console": "warn",
6-
"react/no-unescaped-entities": "warn",
7-
"@next/next/no-img-element": "warn",
8-
"react-hooks/exhaustive-deps": "warn",
10+
"react/no-unescaped-entities": "error",
11+
"@next/next/no-img-element": "error",
12+
"react-hooks/exhaustive-deps": "error",
913
"react-hooks/rules-of-hooks": "error"
1014
}
1115
}

client/.oxlintrc.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"rules": {
3+
"typescript/no-unused-vars": "error",
4+
"react/react-hooks-exhaustive-deps": "error",
5+
"react/rules-of-hooks": "error",
6+
"react/jsx-no-unescaped-entities": "error"
7+
}
8+
}

0 commit comments

Comments
 (0)