| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
oxlint: add unicorn rules (#4157) * oxlint: add unicorn rules * oxlint: curate unicorn rules Go through every unicorn rule, disable the ones that do not fit this codebase, tune the options of the ones that do, and fix the code they flag. Disabled: - `no-null`, `no-useless-undefined`: `null`/`undefined` literals are required by the public `Maybe<T>` API, by React (`useRef<T>(undefined)`, `renderCell: () => null`) and by `noImplicitReturns` - `prefer-number-coercion`: rewrites `parseFloat('10px')` to `Number('10px')` - `prefer-at`: `at(-1)` returns `T | undefined` and is suggested for DOM collections, which have no `at()` - `no-nested-ternary`, `empty-brace-spaces`, `number-literal-case`: oxfmt already owns this - `prefer-includes`, `no-instanceof-array`: duplicate reports - `no-negated-condition`, `prefer-query-selector`: style Tuned: - `filename-case`: camelCase + PascalCase - `switch-case-braces`: `avoid` - `prefer-ternary`: `only-single-line` - `no-array-sort`: `allowAfterSpread` - `max-nested-calls`: `max: 4` Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * website: use `Array.from(value, mapFn)` instead of `[...value].map(mapFn)` Avoids building an intermediate array. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * Extract `getRowTracks` in `useViewportRows` Both call sites built the same `repeat(n, Xpx)`/`Xpx` string. Extracting it removes the duplication and keeps each `gridTemplateRows` append on one line. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * Avoid `Array#entries` allocation in `useCalculatedColumns` `entries()` allocates a `[index, value]` tuple per column. Use an indexed loop instead, matching the other loops in this file. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * Avoid allocating a key list per group in `TreeDataGrid` `expandGroup` re-runs on every expand/collapse and only needed `Object.keys` for `setSize`. Store `setSize` on each group entry instead — it is already known while grouping, in a memo that recomputes far less often — so `expandGroup` can walk the dictionary with `for…in` and no keys array. `groupRows` now uses `Object.keys` + lookup instead of `Object.entries`, which drops one tuple per group. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * website exports: use iterators * review * review * review * dict -> map --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com> | 11 天前 | |
Migrate from ESLint to oxlint (#4119) * Migrate from ESLint to oxlint Replace ESLint with oxlint for JS/TS linting, keeping ESLint only for markdown (`@eslint/markdown` uses ESLint's language plugin API, which oxlint does not support). `.oxlintrc.json` was generated by `@oxlint/migrate --type-aware --with-nursery` and carries over 545 rules at their original `warn` severity. `@eslint-react` and `sonarjs` are loaded as `jsPlugins`; `typescript`, `react` and `vitest` use oxlint's native implementations, so `typescript-eslint`, `eslint-plugin-react-hooks` and `@vitest/eslint-plugin` are no longer needed. Rules that could not be migrated: - the 13 React Compiler rules (`react-hooks/purity`, `preserve-manual-memoization`, …) — oxlint only ships these as an experimental bundled `react/react-compiler` rule - `@eslint-react/no-implicit-key`, `no-leaked-conditional-rendering` and `no-unused-props` — oxlint's JS plugin API cannot supply parser services, so these throw on every file - `@typescript-eslint/naming-convention`, `prefer-destructuring`, `no-unused-private-class-members`, `require-atomic-updates`, `one-var` Three suppressions were added for behavioural differences rather than real defects: `sonarjs/no-redundant-optional` cannot see `exactOptionalPropertyTypes` without type information, and `vitest/no-conditional-expect` flags a helper that is not a test block. The existing directive in `globals.d.ts` moved down a line because oxlint reports the index signature where ESLint reported the interface. `@eslint-react/component-hook-factories` was dropped: it does not exist in that plugin and was silently ignored by ESLint because it was `off`. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> * remove references to .agents * yaml tweaks * fix double lint * settings tweaks * tweak eslint usage * disallow br * add CLAUDE.md symlink * re-enable typeAware * enable typeCheck * symlink -> file * nude sonarjs * tweak settings * tweak rules * fix CLAUDE.md * sort rules * review * use default categories settings * npm dedupe * npm audit fix * update packages, use ^ * couple tweaks --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com> | 12 天前 | |
oxlint: add unicorn rules (#4157) * oxlint: add unicorn rules * oxlint: curate unicorn rules Go through every unicorn rule, disable the ones that do not fit this codebase, tune the options of the ones that do, and fix the code they flag. Disabled: - `no-null`, `no-useless-undefined`: `null`/`undefined` literals are required by the public `Maybe<T>` API, by React (`useRef<T>(undefined)`, `renderCell: () => null`) and by `noImplicitReturns` - `prefer-number-coercion`: rewrites `parseFloat('10px')` to `Number('10px')` - `prefer-at`: `at(-1)` returns `T | undefined` and is suggested for DOM collections, which have no `at()` - `no-nested-ternary`, `empty-brace-spaces`, `number-literal-case`: oxfmt already owns this - `prefer-includes`, `no-instanceof-array`: duplicate reports - `no-negated-condition`, `prefer-query-selector`: style Tuned: - `filename-case`: camelCase + PascalCase - `switch-case-braces`: `avoid` - `prefer-ternary`: `only-single-line` - `no-array-sort`: `allowAfterSpread` - `max-nested-calls`: `max: 4` Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * website: use `Array.from(value, mapFn)` instead of `[...value].map(mapFn)` Avoids building an intermediate array. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * Extract `getRowTracks` in `useViewportRows` Both call sites built the same `repeat(n, Xpx)`/`Xpx` string. Extracting it removes the duplication and keeps each `gridTemplateRows` append on one line. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * Avoid `Array#entries` allocation in `useCalculatedColumns` `entries()` allocates a `[index, value]` tuple per column. Use an indexed loop instead, matching the other loops in this file. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * Avoid allocating a key list per group in `TreeDataGrid` `expandGroup` re-runs on every expand/collapse and only needed `Object.keys` for `setSize`. Store `setSize` on each group entry instead — it is already known while grouping, in a memo that recomputes far less often — so `expandGroup` can walk the dictionary with `for…in` and no keys array. `groupRows` now uses `Object.keys` + lookup instead of `Object.entries`, which drops one tuple per group. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * website exports: use iterators * review * review * review * dict -> map --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com> | 11 天前 | |
Update typescript-eslint config (#3977) * Update typescript-eslint config * update * fix | 6 个月前 | |
Fully configure @eslint-react/eslint-plugin (#3978) | 6 个月前 | |
Expand styling and customization docs (#3933) * Expand styling and customization docs * tweaks * static rowHeight | 7 个月前 | |
TSR: remove verboseFileRoutes, add router file (#3981) | 6 个月前 | |
CI: check `routeTree.gen.ts` (#4122) * CI: check `routeTree.gen.ts` * update routeTree.gen.ts --------- Co-authored-by: Aman Mahajan <amahajan@stratag.com> | 1 个月前 | |
TypeScript@6.0.2 (#4015) | 5 个月前 | |
oxlint: add unicorn rules (#4157) * oxlint: add unicorn rules * oxlint: curate unicorn rules Go through every unicorn rule, disable the ones that do not fit this codebase, tune the options of the ones that do, and fix the code they flag. Disabled: - `no-null`, `no-useless-undefined`: `null`/`undefined` literals are required by the public `Maybe<T>` API, by React (`useRef<T>(undefined)`, `renderCell: () => null`) and by `noImplicitReturns` - `prefer-number-coercion`: rewrites `parseFloat('10px')` to `Number('10px')` - `prefer-at`: `at(-1)` returns `T | undefined` and is suggested for DOM collections, which have no `at()` - `no-nested-ternary`, `empty-brace-spaces`, `number-literal-case`: oxfmt already owns this - `prefer-includes`, `no-instanceof-array`: duplicate reports - `no-negated-condition`, `prefer-query-selector`: style Tuned: - `filename-case`: camelCase + PascalCase - `switch-case-braces`: `avoid` - `prefer-ternary`: `only-single-line` - `no-array-sort`: `allowAfterSpread` - `max-nested-calls`: `max: 4` Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * website: use `Array.from(value, mapFn)` instead of `[...value].map(mapFn)` Avoids building an intermediate array. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * Extract `getRowTracks` in `useViewportRows` Both call sites built the same `repeat(n, Xpx)`/`Xpx` string. Extracting it removes the duplication and keeps each `gridTemplateRows` append on one line. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * Avoid `Array#entries` allocation in `useCalculatedColumns` `entries()` allocates a `[index, value]` tuple per column. Use an indexed loop instead, matching the other loops in this file. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * Avoid allocating a key list per group in `TreeDataGrid` `expandGroup` re-runs on every expand/collapse and only needed `Object.keys` for `setSize`. Store `setSize` on each group entry instead — it is already known while grouping, in a memo that recomputes far less often — so `expandGroup` can walk the dictionary with `for…in` and no keys array. `groupRows` now uses `Object.keys` + lookup instead of `Object.entries`, which drops one tuple per group. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BHDtvyEwsiM6EQJsgdiHt9 * website exports: use iterators * review * review * review * dict -> map --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com> | 11 天前 |
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
| 11 天前 | ||
| 12 天前 | ||
| 11 天前 | ||
| 6 个月前 | ||
| 6 个月前 | ||
| 7 个月前 | ||
| 6 个月前 | ||
| 1 个月前 | ||
| 5 个月前 | ||
| 11 天前 |