Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support react 18 #2515

Merged
merged 9 commits into from
May 10, 2024
Merged

feat: support react 18 #2515

merged 9 commits into from
May 10, 2024

Conversation

jasonzhuang
Copy link
Contributor

@jasonzhuang jasonzhuang commented May 6, 2024

升级react版本,在依赖react-dom的地方升级了用法,使用creatRoot来渲染

Close #2514

Copy link
Member

@sorrycc sorrycc left a comment

Choose a reason for hiding this comment

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

1、不要改 code style
2、不要改版本号
3、peerDependencies 要兼容而不是替换

Copy link
Member

@sorrycc sorrycc left a comment

Choose a reason for hiding this comment

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

做最小改动,不要做风格调整。

package.json Outdated
Comment on lines 46 to 47
"repository": "git@github.com:jasonzhuang/dva18.git"
}
Copy link
Member

Choose a reason for hiding this comment

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

1、去掉 repository
2、结尾得有空行

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

.gitignore Outdated
@@ -8,3 +8,4 @@
/packages/**/node_modules
/packages/**/dist
/lerna-debug.log
.history/
Copy link
Member

Choose a reason for hiding this comment

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

不要加这个。

Copy link
Contributor Author

Choose a reason for hiding this comment

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

我先删掉。但实际上最好有这个说明,不然vscode有些装了这个插件的,会默认生成

@@ -20,7 +20,7 @@ const { connectRouter, routerMiddleware } = routerRedux;
const { isFunction } = utils;
const { useHistory, useLocation, useParams, useRouteMatch } = router;

export default function(opts = {}) {
export default function (opts = {}) {
Copy link
Member

Choose a reason for hiding this comment

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

不要做风格调整,应该是你本地的 prettier 和 dva 的 prettier 版本不一致。

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done, 暂时把vscode上formatOnSave关闭了解决

.prettierrc Outdated
@@ -1,5 +1,6 @@
{
"printWidth": 100,
"singleQuote": true,
"trailingComma": "all"
"trailingComma": "all",
"semi": true
Copy link
Member

Choose a reason for hiding this comment

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

不要做调整。

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done

@sorrycc sorrycc changed the title Dva18 feat: support react 18 May 10, 2024
@sorrycc sorrycc merged commit b02daba into dvajs:master May 10, 2024
1 of 2 checks passed
@sorrycc
Copy link
Member

sorrycc commented May 10, 2024

Bumped dva@3.0.0-alpha.1

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.

有办法兼容react18吗?
2 participants