Skip to content

chore(deps): bump react and @types/react - #25

Closed
dependabot[bot] wants to merge 168 commits into
masterfrom
dependabot/npm_and_yarn/multi-7f19880bf6
Closed

dependabot[bot] wants to merge 168 commits into
masterfrom
dependabot/npm_and_yarn/multi-7f19880bf6

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Sep 18, 2026 •

Copy link
Copy Markdown
Contributor

Bumps react and @types/react. These dependencies needed to be updated together.
Updates react from 18.3.1 to 19.3.0

Release notes

Sourced from react's releases.

19.3.0 (September 9, 2026)

Below is a list of all new features, APIs, and bug fixes.

Read the React 19.3 release post for more information.

New React Features

New React DOM Features

  • browser(): a new react-dom API that returns a usable which errors during server rendering and resolves in the browser. use(browser()) inside a <Suspense> boundary marks a subtree as browser-only without reporting a recoverable error (@​gnoff: #37143, #37241)
    • Added an onBrowserBailout option to the react-dom/server APIs to observe when a subtree defers to the browser (@​gnoff #37193)

Notable changes

All Changes

React

... (truncated)

Changelog

Sourced from react's changelog.

19.3.0 (September 9, 2026)

New React Features

New React DOM Features

  • browser(): a new react-dom API that returns a usable which errors during server rendering and resolves in the browser. use(browser()) inside a <Suspense> boundary marks a subtree as browser-only without reporting a recoverable error (@​gnoff: #37143, #37241)
    • Added an onBrowserBailout option to the react-dom/server APIs to observe when a subtree defers to the browser (@​gnoff #37193)

Notable changes

All Changes

React

... (truncated)

Commits
Maintainer changes

This version was pushed to npm by GitHub Actions, a new releaser for react since your current version.


Updates @types/react from 18.3.31 to 19.3.0

Commits

@dependabot dependabot Bot added the dependencies Dependency and runtime maintenance label Sep 18, 2026
@ruijayfeng

Copy link
Copy Markdown
Contributor

本地复现了失败并验证了修复方案,供合并参考(未推送分支,diff 可直接套用)。

失败根因

typecheck 三处报错源于 React 19 类型收紧:无参 useRef<T>() 不再合法。但更深的问题是分组不完整:本 PR 把 react/@types/react 升到 19,react-dom 却留在 18——修完 useRef 后 typecheck 能过,运行时 SSR 直接崩:

TypeError: Cannot read properties of undefined (reading 'ReactCurrentDispatcher')
    at node_modules/react-dom/cjs/react-server-dom-.../react-dom-server-legacy.node.development.js

(react-dom 18 读 react 19 已移走的内部结构;tutorial-presentation.test.mjs 稳定复现。)

已验证的最小完整方案

  1. 版本集合补齐:react-dom: ^19.3.0、@types/react-dom: ~19.3.0
  2. 两处无参 useRef 改为显式含 undefined(共 2 行;QCodeWorld.tsx:370 的 = undefined 在新类型下无需改动):
- const pickerAbort = useRef<AbortController>()
+ const pickerAbort = useRef<AbortController | undefined>(undefined)
- const current = useRef<TutorialRun>()
+ const current = useRef<TutorialRun | undefined>(undefined)

验证结果(macOS arm64 / Node 26.8.1)

  • yarn typecheck 退出 0
  • yarn build:web 通过
  • node --test packages/qcode-web/tests/*.test.mjs:61/61 通过(含 SSR 呈现测试)

类型与测试全绿,但 React 19 是 major 升级,合并前建议照旧跑一次浏览器人工走查。另注:#13 首批将触碰 Tutorial.tsx / QCodeWorld.tsx 同批文件,届时会保持新旧类型双兼容写法。

ruijayfeng and others added 2 commits September 22, 2026 09:58
@dependabot
dependabot Bot force-pushed the dependabot/npm_and_yarn/multi-7f19880bf6 branch from ca87bd6 to fbb5803 Compare September 22, 2026 02:04
dependabot Bot and others added 10 commits September 22, 2026 10:07
Dependabot GitHub Actions update; required checks passed on the updated branch.
Dependabot GitHub Actions update; required checks passed on the updated branch.
Dependabot GitHub Actions update; required checks passed on the updated branch.
Dependabot GitHub Actions update; required checks passed on the updated branch.
Dependabot GitHub Actions update; required checks passed on the updated branch.
Dependabot update; synchronized with master and all CI checks pass.
@dependabot
dependabot Bot force-pushed the dependabot/npm_and_yarn/multi-7f19880bf6 branch from fbb5803 to 15997f2 Compare September 23, 2026 01:05
Dependabot update reconciled with tsdown 0.23.0; all CI checks pass.
Bumps [react](https://github.com/react/react/tree/HEAD/packages/react) and [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react). These dependencies needed to be updated together.

Updates `react` from 18.3.1 to 19.3.0
- [Release notes](https://github.com/react/react/releases)
- [Changelog](https://github.com/react/react/blob/main/CHANGELOG.md)
- [Commits](https://github.com/react/react/commits/v19.3.0/packages/react)

Updates `@types/react` from 18.3.31 to 19.3.0
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: "@types/react"
  dependency-version: 19.3.0
  dependency-type: direct:development
  update-type: version-update:semver-major
- dependency-name: react
  dependency-version: 19.3.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot
dependabot Bot force-pushed the dependabot/npm_and_yarn/multi-7f19880bf6 branch from 15997f2 to a75afea Compare September 23, 2026 01:27
@Qiuner

Qiuner commented Sep 23, 2026

Copy link
Copy Markdown
Owner

Web checks 当前失败于 TypeScript/React 19 类型兼容:src/client/QCodeWorld.tsx:166、:370 和 src/client/Tutorial.tsx:18,分别出现参数数量与 AbortController | undefined 不匹配。请修复这些类型错误并补充验证后再合并;暂不批准合并。

@dependabot @github

dependabot Bot commented on behalf of github Sep 28, 2026

Copy link
Copy Markdown
Contributor Author

OK, I won't notify you again about this release, but will get in touch when a new version is available. You can also ignore all major, minor, or patch releases for a dependency by adding an ignore condition with the desired update_types to your config file.

If you change your mind, just re-open this PR and I'll resolve any conflicts on it.

@dependabot
dependabot Bot deleted the dependabot/npm_and_yarn/multi-7f19880bf6 branch September 28, 2026 04:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Dependency and runtime maintenance

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants