Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,21 @@ jobs:
with:
node-version: 26
package-manager-cache: false
- name: Setup pnpm
uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
- name: Setup nub
uses: nubjs/setup-nub@47e5e7393d50f4e9544ddaf756aa277972afba2d # v0.4.0
- name: Install dependencies
run: pnpm install --frozen-lockfile
run: nub install --frozen-lockfile
- name: Check formatting
run: node --run format:check
run: nub run format:check
- name: Build packages
run: node --run build
run: nub run build
- name: Lint
run: node --run lint
run: nub run lint
- name: Verify rules
run: node --run check:rules
run: nub run check:rules
- name: Lint MDX
run: node --run lint:mdx
run: nub run lint:mdx
- name: Check website types
run: pnpm -F "./apps/website" run types:check
run: nub run --filter "./apps/website" types:check
- name: Verify generated files are up to date
run: git --no-pager diff --exit-code
16 changes: 8 additions & 8 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,26 +29,26 @@ jobs:
with:
node-version: 26
package-manager-cache: false
- name: Setup pnpm
uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
- name: Setup nub
uses: nubjs/setup-nub@47e5e7393d50f4e9544ddaf756aa277972afba2d # v0.4.0
- name: Install dependencies
run: pnpm install --frozen-lockfile --ignore-scripts
run: nub install --frozen-lockfile --ignore-scripts
- name: Build packages
run: node --run build
run: nub run build
- name: Publish
run: |
if git log -1 --pretty=%B | grep "^release: [0-9]\+\.[0-9]\+\.[0-9]\+$";
then
pnpm --filter "./packages/*" --filter "./plugins/*" publish --provenance --access public
nub --filter "./packages/*" --filter "./plugins/*" publish --provenance --access public
elif git log -1 --pretty=%B | grep "^release: [0-9]\+\.[0-9]\+\.[0-9]\+-rc\.[0-9]\+$";
then
pnpm --filter "./packages/*" --filter "./plugins/*" publish --provenance --access public --tag rc --no-git-checks
nub --filter "./packages/*" --filter "./plugins/*" publish --provenance --access public --tag rc --no-git-checks
elif git log -1 --pretty=%B | grep "^release: [0-9]\+\.[0-9]\+\.[0-9]\+-beta\.[0-9]\+$";
then
pnpm --filter "./packages/*" --filter "./plugins/*" publish --provenance --access public --tag beta --no-git-checks
nub --filter "./packages/*" --filter "./plugins/*" publish --provenance --access public --tag beta --no-git-checks
elif git log -1 --pretty=%B | grep "^release: [0-9]\+\.[0-9]\+\.[0-9]\+-next\.[0-9]\+$";
then
pnpm --filter "./packages/*" --filter "./plugins/*" publish --provenance --access public --tag next --no-git-checks
nub --filter "./packages/*" --filter "./plugins/*" publish --provenance --access public --tag next --no-git-checks
Comment thread
Rel1cx marked this conversation as resolved.
else
echo "Not a release, skipping publish"
fi
10 changes: 5 additions & 5 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@ jobs:
node-version: 26
package-manager-cache: false

- name: Setup pnpm
uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
- name: Setup nub
uses: nubjs/setup-nub@47e5e7393d50f4e9544ddaf756aa277972afba2d # v0.4.0

- name: Install dependencies
run: pnpm install --frozen-lockfile --ignore-scripts
run: nub install --frozen-lockfile --ignore-scripts

- name: Build
run: node --run build
run: nub run build

- name: Determine release info
id: release
Expand Down Expand Up @@ -75,7 +75,7 @@ jobs:
if: steps.release.outputs.is_release == 'true'
run: |
for dir in packages/*/ plugins/*/; do
(cd "$dir" && pnpm pack)
(cd "$dir" && nub pack)
done

- name: Attest packages
Expand Down
18 changes: 7 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,29 +27,25 @@ jobs:
with:
node-version: 26
package-manager-cache: false
- name: Setup pnpm
uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
- name: Setup nub
uses: nubjs/setup-nub@47e5e7393d50f4e9544ddaf756aa277972afba2d # v0.4.0
- name: Install dependencies
run: pnpm install --frozen-lockfile
run: nub install --frozen-lockfile
- name: Build packages
run: node --run build
run: nub run build
- name: Test on node@26
run: node --run test
run: nub run test
- name: Setup node@24
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
with:
node-version: 24
package-manager-cache: false
- name: Setup pnpm
uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
- name: Test on node@24
run: node --run test
run: nub run test
- name: Setup node@22
uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0
with:
node-version: 22
package-manager-cache: false
- name: Setup pnpm
uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9
- name: Test on node@22
run: node --run test
run: nub run test
2 changes: 1 addition & 1 deletion .pkgs/eff/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"devDependencies": {
"@local/configs": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion .pkgs/samples/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build:docs && node --run lint:publish"
"publish": "nub run build:docs && nub run lint:publish"
},
"dependencies": {
"@eslint-react/kit": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion .pkgs/testkit/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build:docs && node --run lint:publish"
"publish": "nub run build:docs && nub run lint:publish"
},
"dependencies": {
"@typescript-eslint/parser": "^8.64.0",
Expand Down
5 changes: 5 additions & 0 deletions apps/website/vercel.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"$schema": "https://openapi.vercel.sh/vercel.json",
"installCommand": "cd ../.. && npm install --global --ignore-scripts=false @nubjs/nub && nub install",
"buildCommand": "nub run build"
}
4 changes: 2 additions & 2 deletions docs/rule-feature-system.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const RULE_FEATURES = ["EXP"]; // static-components: experimental detection

## How Features Drive Presets

Feature metadata is the source of truth for badges and categorization, but the preset files themselves are maintained manually. The `scripts/20-check-rules.ts` script (run via `node --run check:rules`) verifies config consistency—registered rules are accounted for, config keys are valid, and preset hierarchies hold—but it does not check `RULE_FEATURES` flags. Keeping `disable-type-checked` and `disable-experimental` aligned with `RULE_FEATURES` is currently a manual step.
Feature metadata is the source of truth for badges and categorization, but the preset files themselves are maintained manually. The `scripts/20-check-rules.ts` script (run via `nub run check:rules`) verifies config consistency—registered rules are accounted for, config keys are valid, and preset hierarchies hold—but it does not check `RULE_FEATURES` flags. Keeping `disable-type-checked` and `disable-experimental` aligned with `RULE_FEATURES` is currently a manual step.

Rules marked `TSC` are disabled in `disable-type-checked.ts`:

Expand Down Expand Up @@ -86,5 +86,5 @@ export const rules: Linter.RulesRecord = {
2. Remove the rule from `disable-experimental.ts`.
3. Add it to `recommended.ts` or `strict.ts`.
4. Remove experimental warnings from its `.mdx` docs.
5. Run `node --run check:rules`.
5. Run `nub run check:rules`.
6. Update `CHANGELOG.md`.
10 changes: 5 additions & 5 deletions docs/rule-rename-checklist.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ Checklist for renaming or moving rules in `eslint-plugin-react-x` and `@eslint-r

### A9. Verify

- [ ] `pnpm tsc --noEmit`
- [ ] `pnpm vitest run src/rules/<new-name>/<new-name>.spec.ts`
- [ ] `nub exec tsc --noEmit`
- [ ] `nub exec vitest run src/rules/<new-name>/<new-name>.spec.ts`
- [ ] `grep -r --exclude-dir=node_modules --exclude-dir=dist "<old-name>" plugins/ packages/` — no leftover references

---
Expand All @@ -67,7 +67,7 @@ Checklist for renaming or moving rules in `eslint-plugin-react-x` and `@eslint-r
### B1. Dependencies

- [ ] Check if the source plugin uses dependencies not yet listed in `eslint-plugin-react-x/package.json`.
- [ ] Add any missing dependencies and run `pnpm install --filter eslint-plugin-react-x`.
- [ ] Add any missing dependencies and run `nub install --filter eslint-plugin-react-x`.

### B2. New Source Files (in `eslint-plugin-react-x`)

Expand Down Expand Up @@ -111,8 +111,8 @@ Checklist for renaming or moving rules in `eslint-plugin-react-x` and `@eslint-r

### B8. Verify

- [ ] `pnpm tsc --noEmit` in all affected packages.
- [ ] `pnpm vitest run src/rules/<rule-name>/<rule-name>.spec.ts`
- [ ] `nub exec tsc --noEmit` in all affected packages.
- [ ] `nub exec vitest run src/rules/<rule-name>/<rule-name>.spec.ts`
- [ ] `grep -r --exclude-dir=node_modules --exclude-dir=dist "react-<source>/<rule-name>" plugins/ packages/` — no stale references

---
Expand Down
3 changes: 3 additions & 0 deletions nx.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
"parallel": 8,
"cacheDirectory": ".nx/cache",
"defaultBase": "main",
"cli": {
"packageManager": "npm"
},
"namedInputs": {
"default": [
"{projectRoot}/**/*",
Expand Down
28 changes: 13 additions & 15 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,32 +28,32 @@
"author": "Rel1cx",
"type": "module",
"scripts": {
"build": "node --run build:pkgs && node --run build:packages && node --run build:plugins",
"build": "nub run build:pkgs && nub run build:packages && nub run build:plugins",
"build:docs": "nx run-many -t build:docs --parallel",
"build:packages": "nx run-many -t build -p 'packages/*' --parallel",
"build:pkgs": "nx run-many -t build -p '.pkgs/*' --parallel",
"build:plugins": "nx run-many -t build -p 'plugins/*' --parallel",
"build:website": "node --run update:website && pnpm -F \"./apps/website\" run build",
"check:rules": "vite-node -c vitest.config.ts ./scripts/20-check-rules.ts",
"build:website": "nub run update:website && nub run --filter \"./apps/website\" build",
"check:rules": "nub ./scripts/20-check-rules.ts",
"format:check": "dprint check",
"format:write": "dprint fmt",
"lint": "node --run lint:publish && node --run lint:ts && node --run lint:es && node --run lint:examples && node --run lint:text",
"lint": "nub run lint:publish && nub run lint:ts && nub run lint:es && nub run lint:examples && nub run lint:text",
"lint:es": "eslint . --max-warnings 100 --concurrency=auto",
"lint:examples": "pnpm m -F \"./examples/*\" run lint",
"lint:examples": "nub run --filter \"./examples/*\" lint",
"lint:mdx": "mdxlint plugins/**/*.mdx apps/**/*.mdx --frail --no-stdout",
"lint:mdx:write": "mdxlint plugins/**/*.mdx -o && mdxlint apps/**/*.mdx -o",
"lint:publish": "nx run-many -t lint:publish --parallel",
"lint:text": "textlint '**/*.md' '**/*.mdx'",
"lint:ts": "nx run-many -t lint:ts --parallel",
"lint:website": "pnpm -F \"./apps/website\" run lint",
"prepare": "node --run update:all && node --run build",
"scaffold:rule": "vite-node ./scripts/90-scaffold-rule.ts",
"sort:package-json": "pnpm m exec sort-package-json -q package.json && dprint fmt",
"lint:website": "nub run --filter \"./apps/website\" lint",
"prepare": "nub run update:all && nub run build",
"scaffold:rule": "nub ./scripts/90-scaffold-rule.ts",
"sort:package-json": "nub exec sort-package-json -q \".pkgs/*/package.json\" \"apps/*/package.json\" \"packages/*/package.json\" \"plugins/*/package.json\" \"examples/*/package.json\" && dprint fmt",
"test": "vitest run --logHeapUsage",
"update:all": "node --run update:version && node --run update:readme && node --run update:website",
"update:readme": "vite-node ./scripts/11-update-readme.ts",
"update:version": "vite-node ./scripts/10-update-version.ts",
"update:website": "vite-node ./scripts/12-update-website.ts"
"update:all": "nub run update:version && nub run update:readme && nub run update:website",
"update:readme": "nub ./scripts/11-update-readme.ts",
"update:version": "nub ./scripts/10-update-version.ts",
"update:website": "nub ./scripts/12-update-website.ts"
},
"devDependencies": {
"@effect/language-service": "^0.86.6",
Expand Down Expand Up @@ -104,10 +104,8 @@
"typedoc-plugin-mdn-links": "^5.1.1",
"typescript": "6.0.3",
"typescript-eslint": "^8.64.0",
"vite-node": "^6.0.0",
"vitest": "^4.1.10"
},
"packageManager": "pnpm@11.15.0",
"engines": {
"node": ">=22.0.0"
}
Expand Down
2 changes: 1 addition & 1 deletion packages/ast/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@typescript-eslint/types": "^8.64.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion packages/eslint/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@typescript-eslint/utils": "^8.64.0"
Expand Down
2 changes: 1 addition & 1 deletion packages/jsx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion packages/kit/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion packages/shared/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/eslint": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion packages/var/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"build:docs": "typedoc",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion plugins/eslint-plugin-react-debug/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"build": "tsdown",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion plugins/eslint-plugin-react-dom/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"build": "tsdown",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion plugins/eslint-plugin-react-jsx/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"build": "tsdown",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion plugins/eslint-plugin-react-naming-convention/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"build": "tsdown",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion plugins/eslint-plugin-react-rsc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
"build": "tsdown",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
2 changes: 1 addition & 1 deletion plugins/eslint-plugin-react-web-api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
"build": "tsdown",
"lint:publish": "publint",
"lint:ts": "tsl",
"publish": "node --run build && node --run lint:publish"
"publish": "nub run build && nub run lint:publish"
},
"dependencies": {
"@eslint-react/ast": "workspace:*",
Expand Down
Loading
Loading