-
Notifications
You must be signed in to change notification settings - Fork 248
Closed
Labels
staleIssue that may be closed soon due to the original author not responding any more.Issue that may be closed soon due to the original author not responding any more.
Description
问题描述
react 19使用XFlow的时候报错:
package.json:
{
"name": "react-demo-34-x6cutomnode",
"private": true,
"version": "0.0.0",
"type": "module",
"scripts": {
"dev": "vite",
"build": "tsc -b && vite build",
"lint": "eslint .",
"preview": "vite preview"
},
"dependencies": {
"@antv/x6-react-shape": "^2.2.3",
"@antv/xflow": "^2.1.13",
"less": "^4.2.2",
"react": "^19.0.0",
"react-dom": "^19.0.0"
},
"devDependencies": {
"@eslint/js": "^9.21.0",
"@types/react": "^19.0.10",
"@types/react-dom": "^19.0.4",
"@vitejs/plugin-react": "^4.3.4",
"eslint": "^9.21.0",
"eslint-plugin-react-hooks": "^5.1.0",
"eslint-plugin-react-refresh": "^0.4.19",
"globals": "^15.15.0",
"typescript": "~5.7.2",
"typescript-eslint": "^8.24.1",
"vite": "^6.2.0"
}
}
报错信息:
chunk-I3XHVTQD.js?v=7ebed848:365 Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release.
重现链接
https://codesandbox.io/s/wr7k8w
重现步骤
1、创建react项目
2、确认package.json的react版本:
"react": "^19.0.0",
3、安装使用XFlow
pnpm install @antv/xflow less --save
4、配置使用XFlow
5、运行
预期行为
期望无报错;
报错信息:
平台
- 操作系统: [macOS]
- 网页浏览器: [Google Chrome, Safari, Firefox]
- XFlow 版本: [^2.1.13 ]
- React版本:[19.0.0]
屏幕截图或视频(可选)
补充说明(可选)
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
staleIssue that may be closed soon due to the original author not responding any more.Issue that may be closed soon due to the original author not responding any more.

