Skip to content

Conversation

@JounQin
Copy link
Member

@JounQin JounQin commented Oct 15, 2025

Summary by CodeRabbit

  • Style

    • Hides the “before” marker on the first H2 in the overview index for a cleaner heading appearance.
  • Bug Fixes

    • Improves template path resolution during project scaffolding to ensure correct folder/file generation.
  • Chores

    • Raises minimum Node.js requirement to 20.19+ and updates .nvmrc.
    • Updates Yarn to 4.10.3.
    • Bumps various dev dependencies and internal package minor versions.
    • Updates CI to test on Node.js 20/22/24 (drops 18).

Copilot AI review requested due to automatic review settings October 15, 2025 04:51
@changeset-bot
Copy link

changeset-bot bot commented Oct 15, 2025

🦋 Changeset detected

Latest commit: e64fb8d

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
@alauda/doom Minor
@alauda/doom-export Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@coderabbitai
Copy link

coderabbitai bot commented Oct 15, 2025

Note

Other AI code review bot(s) detected

CodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review.

Walkthrough

This PR updates Node/Yarn tooling and dev dependencies, adjusts ESLint config usage, tightens engines for packages, modifies CI Node matrix, tweaks a CLI path-mapping line in scaffolding, adds minor style and lint-comment changes, and introduces a changeset for minor releases of @alauda/doom and @alauda/doom-export.

Changes

Cohort / File(s) Summary
Repo tooling & release meta
/.changeset/slow-mice-doubt.md, /.nvmrc, /.yarnrc.yml, /.github/workflows/ci.yml
Adds changeset for minor bumps; updates Node to 24.10.0; updates Yarn to 4.10.3; removes Node 18 from CI matrix (keeps 20/22/24).
Root config & lint
/package.json, /eslint.config.js
Bumps devDeps (@eslint/js, eslint, typescript, @types/*, eslint-plugin-react-hooks v7); switches react-hooks plugin import to default and uses configs.flat.recommended.
Packages: engines & dependencies
/packages/doom/package.json, /packages/export/package.json
Raises engines to Node >=20.19.0. Updates multiple deps (eslint, typescript, openai v6, string-width v8, etc.). Removes @playwright/browser-chromium from doom; adds it to export and bumps playwright to 1.56.0.
CLI scaffolding mapping
/packages/doom/src/cli/new.ts
Changes path resolution for template file mapping to use path.resolve(d.parentPath, d.name) without fallback to d.path.
Runtime lint/comment tweaks
/packages/doom/src/global/VersionsNav/index.tsx, /packages/doom/src/runtime/components/OpenAPIRef.tsx, /packages/doom/src/runtime/hooks/useInterval.ts, /packages/doom/src/runtime/hooks/useMemoizedFn.ts, /packages/doom/src/runtime/hooks/useIsPrint.ts
Adds/adjusts ESLint directives; renames state setter to setIsPrint in useIsPrint; no functional changes except naming.
Styles
/packages/doom/styles/overview.module.scss
Hides :before pseudo-element for the first h2 in overview index.

Sequence Diagram(s)

sequenceDiagram
  autonumber
  actor User
  participant CLI as CLI new
  participant Walker as FileWalker
  participant Mapper as TemplateMapper
  participant Tracker as FileTracker

  User->>CLI: run doom new
  CLI->>Walker: enumerate template files
  Walker-->>CLI: file descriptors (name, parentPath)
  CLI->>Mapper: path.resolve(d.parentPath, d.name)
  note right of Mapper: Changed from fallback to d.path
  Mapper-->>Tracker: relative path from source
  Tracker-->>User: scaffolded file list
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related issues

  • Dependency Dashboard #115 — Aligns with dependency and engine updates (Node/Yarn/ESLint/hooks, OpenAI, Playwright) covered in this PR.

Possibly related PRs

Suggested labels

dependencies

Poem

I thump my paws at version cheer,
New yarn to spin, Node’s path made clear.
Hooks hush softly, linting tight,
Scaffolds map their files just right.
Playwright bows, exports sing—
Minor bumps, a springy spring! 🐇✨

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The title succinctly and accurately describes the primary purpose of the pull request, which is to bump all dependencies (including devDependencies), matching the extensive version updates across multiple package files and configuration. It follows conventional commit style with the “chore” prefix and clearly conveys the main change without unnecessary details. It is concise, specific, and understandable at a glance.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch chore/deps

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 381ee50 and e64fb8d.

⛔ Files ignored due to path filters (2)
  • .yarn/releases/yarn-4.10.3.cjs is excluded by !**/.yarn/**
  • yarn.lock is excluded by !**/yarn.lock, !**/*.lock
📒 Files selected for processing (15)
  • .changeset/slow-mice-doubt.md (1 hunks)
  • .github/workflows/ci.yml (0 hunks)
  • .nvmrc (1 hunks)
  • .yarnrc.yml (1 hunks)
  • eslint.config.js (2 hunks)
  • package.json (3 hunks)
  • packages/doom/package.json (5 hunks)
  • packages/doom/src/cli/new.ts (1 hunks)
  • packages/doom/src/global/VersionsNav/index.tsx (1 hunks)
  • packages/doom/src/runtime/components/OpenAPIRef.tsx (1 hunks)
  • packages/doom/src/runtime/hooks/useInterval.ts (1 hunks)
  • packages/doom/src/runtime/hooks/useIsPrint.ts (1 hunks)
  • packages/doom/src/runtime/hooks/useMemoizedFn.ts (1 hunks)
  • packages/doom/styles/overview.module.scss (1 hunks)
  • packages/export/package.json (2 hunks)
💤 Files with no reviewable changes (1)
  • .github/workflows/ci.yml
🧰 Additional context used
📓 Path-based instructions (7)
**/*.{ts,tsx,js,jsx,md,yml,yaml,json}

📄 CodeRabbit inference engine (AGENTS.md)

Format code using the repository’s Prettier configuration (yarn format)

Files:

  • packages/doom/src/global/VersionsNav/index.tsx
  • packages/doom/src/runtime/hooks/useMemoizedFn.ts
  • eslint.config.js
  • packages/doom/src/runtime/components/OpenAPIRef.tsx
  • packages/doom/src/runtime/hooks/useInterval.ts
  • packages/doom/src/runtime/hooks/useIsPrint.ts
  • packages/export/package.json
  • package.json
  • packages/doom/src/cli/new.ts
  • packages/doom/package.json
**/*.{ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

**/*.{ts,tsx}: Code must adhere to TypeScript strict-mode rules (no implicit any, strict null checks, etc.)
Maintain strong type coverage; validate with yarn typecov

Files:

  • packages/doom/src/global/VersionsNav/index.tsx
  • packages/doom/src/runtime/hooks/useMemoizedFn.ts
  • packages/doom/src/runtime/components/OpenAPIRef.tsx
  • packages/doom/src/runtime/hooks/useInterval.ts
  • packages/doom/src/runtime/hooks/useIsPrint.ts
  • packages/doom/src/cli/new.ts
**/*.{ts,tsx,js,jsx}

📄 CodeRabbit inference engine (AGENTS.md)

Follow ESLint project-specific rules; avoid disabling rules without justification

Files:

  • packages/doom/src/global/VersionsNav/index.tsx
  • packages/doom/src/runtime/hooks/useMemoizedFn.ts
  • eslint.config.js
  • packages/doom/src/runtime/components/OpenAPIRef.tsx
  • packages/doom/src/runtime/hooks/useInterval.ts
  • packages/doom/src/runtime/hooks/useIsPrint.ts
  • packages/doom/src/cli/new.ts
packages/**

📄 CodeRabbit inference engine (AGENTS.md)

Organize code as a Yarn workspaces monorepo; place package code under packages/

Files:

  • packages/doom/src/global/VersionsNav/index.tsx
  • packages/doom/src/runtime/hooks/useMemoizedFn.ts
  • packages/doom/styles/overview.module.scss
  • packages/doom/src/runtime/components/OpenAPIRef.tsx
  • packages/doom/src/runtime/hooks/useInterval.ts
  • packages/doom/src/runtime/hooks/useIsPrint.ts
  • packages/export/package.json
  • packages/doom/src/cli/new.ts
  • packages/doom/package.json
packages/doom/**

📄 CodeRabbit inference engine (AGENTS.md)

Place the main documentation tool and CLI in packages/doom/

Files:

  • packages/doom/src/global/VersionsNav/index.tsx
  • packages/doom/src/runtime/hooks/useMemoizedFn.ts
  • packages/doom/styles/overview.module.scss
  • packages/doom/src/runtime/components/OpenAPIRef.tsx
  • packages/doom/src/runtime/hooks/useInterval.ts
  • packages/doom/src/runtime/hooks/useIsPrint.ts
  • packages/doom/src/cli/new.ts
  • packages/doom/package.json
eslint.config.js

📄 CodeRabbit inference engine (AGENTS.md)

Define and update linting rules in eslint.config.js

Files:

  • eslint.config.js
packages/export/**

📄 CodeRabbit inference engine (AGENTS.md)

Place document export functionality in packages/export/

Files:

  • packages/export/package.json
🧠 Learnings (5)
📓 Common learnings
Learnt from: JounQin
PR: alauda/doom#30
File: src/runtime/components/K8sCrd.tsx:5-5
Timestamp: 2025-05-26T09:09:21.339Z
Learning: The alauda/doom project uses yarn v4 for dependency management, which handles package exports and module resolution correctly, so imports like `rspress/core/theme` work without any ESLint errors.
📚 Learning: 2025-06-06T07:08:55.881Z
Learnt from: JounQin
PR: alauda/doom#69
File: package.json:101-101
Timestamp: 2025-06-06T07:08:55.881Z
Learning: When a package has peer dependencies that require TypeScript (like `eslint-react/eslint-plugin`), TypeScript should be moved from devDependencies to dependencies to satisfy the peer dependency requirement.

Applied to files:

  • package.json
📚 Learning: 2025-09-24T04:08:32.103Z
Learnt from: CR
PR: alauda/doom#0
File: AGENTS.md:0-0
Timestamp: 2025-09-24T04:08:32.103Z
Learning: Applies to **/*.{ts,tsx} : Maintain strong type coverage; validate with yarn typecov

Applied to files:

  • package.json
📚 Learning: 2025-09-24T04:08:32.103Z
Learnt from: CR
PR: alauda/doom#0
File: AGENTS.md:0-0
Timestamp: 2025-09-24T04:08:32.103Z
Learning: Use Node.js 18.17.0+ (avoid 20.0.0; use 20.1.0+ if on Node 20)

Applied to files:

  • packages/doom/package.json
📚 Learning: 2025-05-26T09:09:21.339Z
Learnt from: JounQin
PR: alauda/doom#30
File: src/runtime/components/K8sCrd.tsx:5-5
Timestamp: 2025-05-26T09:09:21.339Z
Learning: The alauda/doom project uses yarn v4 for dependency management, which handles package exports and module resolution correctly, so imports like `rspress/core/theme` work without any ESLint errors.

Applied to files:

  • packages/doom/package.json
🪛 LanguageTool
.changeset/slow-mice-doubt.md

[grammar] ~6-~6: There might be a mistake here.
Context: ...xport": minor --- chore: bump all (dev)Dependencies

(QB_NEW_EN)

🔇 Additional comments (17)
packages/doom/src/cli/new.ts (1)

248-248: Dirent.parentPath support confirmed. packages/doom requires Node.js >=20.19.0, which covers the Dirent.parentPath API (introduced in 20.1.0); removing the d.path fallback is safe.

.nvmrc (1)

1-1: LGTM!

Node.js version update from 24.7.0 to 24.10.0 aligns with the dependency refresh and CI matrix adjustments in this PR.

.yarnrc.yml (1)

10-10: LGTM!

Yarn version update from 4.9.4 to 4.10.3 is consistent with the dependency refresh objectives.

packages/doom/src/runtime/hooks/useMemoizedFn.ts (1)

9-10: LGTM!

The lint directive appropriately suppresses warnings for the intentional ref update pattern used in this memoized callback hook.

packages/doom/src/runtime/hooks/useInterval.ts (1)

7-8: LGTM!

The lint directive correctly suppresses warnings for the intentional callback ref update pattern, ensuring the interval always invokes the latest callback.

packages/doom/src/runtime/hooks/useIsPrint.ts (2)

24-25: LGTM!

The lint directive is necessary because printMediaQuery only destructures the state value without the setter, which doesn't follow the typical [value, setValue] convention that the ESLint rule enforces.


27-30: LGTM!

Renaming changeIsPrint to setIsPrint improves consistency with React naming conventions (set + state variable name).

packages/doom/src/runtime/components/OpenAPIRef.tsx (1)

179-191: LGTM!

The lint directive appropriately suppresses warnings for the intentional manual memoization of the OpenAPI schema search logic, which correctly depends on openapiPath_ and schema.

packages/doom/src/global/VersionsNav/index.tsx (1)

116-117: LGTM!

The updated lint directive now includes both the legacy rule name (@eslint-react/hooks-extra/no-direct-set-state-in-use-effect) and the current rule name (react-hooks/set-state-in-effect), correctly suppressing warnings for the intentional setState pattern used to detect nav menu recreation.

.changeset/slow-mice-doubt.md (1)

1-6: LGTM!

The changeset correctly specifies minor version bumps for both packages. The "(dev)Dependencies" notation intentionally indicates updates to both dependencies and devDependencies; the static analysis hint is a false positive.

packages/export/package.json (1)

14-14: LGTM! Engine and dependency updates are well-aligned.

The engine constraint update to Node 20.19.0+ aligns with the broader repository strategy, and the Playwright dependency updates with exact version pins ensure reproducible builds.

Also applies to: 25-25, 30-30

packages/doom/styles/overview.module.scss (1)

5-7: LGTM! Minor style refinement.

The CSS rule appropriately hides the decorative pseudo-element on the first heading in the overview index.

package.json (2)

13-13: LGTM! Dependency updates are consistent.

The package manager and devDependency updates align with the PR objectives. The eslint-plugin-react-hooks upgrade to v7 is properly addressed in eslint.config.js.

Also applies to: 36-36, 42-42, 49-49, 52-52, 61-61


45-46: Manually verify TS compilation after React v19 upgrade
Run yarn install && yarn typecov to confirm no type errors with @types/react/@types/react-dom v19.

eslint.config.js (1)

7-7: LGTM! Correctly migrated to react-hooks plugin v7 API.

The import and config path changes properly align with the new API surface in eslint-plugin-react-hooks v7, which now provides flat configs via the default export.

Also applies to: 22-22

packages/doom/package.json (2)

14-14: LGTM! Engine constraint aligns with repository strategy.

The Node engine constraint of >=20.19.0 is consistent with the packages/export package and the broader Node 20+ alignment across the repository.


44-105: Verify compatibility with major dependency updates.

Multiple dependencies have major version bumps (e.g., commander ^14, string-width ^8, type-fest ^5, typescript-eslint ^8) that may introduce breaking changes.

Run the following script to verify the build and tests pass:


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Signed-off-by: JounQin <admin@1stg.me>
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates all (dev)dependencies across the project to their latest versions and makes associated configuration changes to support the upgrades.

  • Updates Node.js engine requirements from multiple version ranges to a simplified >=20.19.0
  • Upgrades numerous dependencies including ESLint, TypeScript, React types, and various plugins
  • Adjusts ESLint configuration to use new flat config format for react-hooks plugin

Reviewed Changes

Copilot reviewed 14 out of 16 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
packages/export/package.json Updates Node.js engine requirement and Playwright dependencies
packages/doom/styles/overview.module.scss Adds CSS rule to hide first h2 element's ::before pseudo-element
packages/doom/src/runtime/hooks/useMemoizedFn.ts Adds ESLint disable comment for react-hooks/refs rule
packages/doom/src/runtime/hooks/useIsPrint.ts Renames state setter and adds ESLint disable comment
packages/doom/src/runtime/hooks/useInterval.ts Adds ESLint disable comment for react-hooks/refs rule
packages/doom/src/runtime/components/OpenAPIRef.tsx Adds ESLint disable comment for react-hooks/preserve-manual-memoization
packages/doom/src/global/VersionsNav/index.tsx Updates ESLint disable comment to include additional rule
packages/doom/src/cli/new.ts Simplifies path resolution by removing deprecated fallback
packages/doom/package.json Updates Node.js engine and multiple dependencies to latest versions
package.json Updates package manager and dev dependencies
eslint.config.js Changes react-hooks plugin import and config usage for flat config
.yarnrc.yml Updates Yarn version path
.nvmrc Updates Node.js version

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Oct 15, 2025

Open in StackBlitz

yarn add https://pkg.pr.new/@alauda/doom@190.tgz
yarn add https://pkg.pr.new/@alauda/doom-export@190.tgz

commit: e64fb8d

@JounQin JounQin merged commit d131ade into main Oct 15, 2025
14 checks passed
@JounQin JounQin deleted the chore/deps branch October 15, 2025 05:11
github-actions bot pushed a commit that referenced this pull request Oct 15, 2025
Signed-off-by: JounQin <admin@1stg.me>
@coderabbitai coderabbitai bot mentioned this pull request Dec 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants