Skip to content

Feat RN原生组件标签支持使用class/style#2163

Merged
mackwang112 merged 10 commits intomasterfrom
feat-nativecomponent-style
Aug 26, 2025
Merged

Feat RN原生组件标签支持使用class/style#2163
mackwang112 merged 10 commits intomasterfrom
feat-nativecomponent-style

Conversation

@mackwang112
Copy link
Collaborator

No description provided.

Object.assign(result, transformStyleObj(styleObj))
const styleObj = {}
if (isNativeStaticStyle) {
if (Array.isArray()) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

这是干嘛的

Copy link
Collaborator

Choose a reason for hiding this comment

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

少传递参数了吧

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

这个if不需要的,已修改

})
}

return isEmptyObject(result) ? empty : result
Copy link
Collaborator

Choose a reason for hiding this comment

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

isEmpty的判断不严谨,比如style传递一个空数组 []

Copy link
Collaborator

Choose a reason for hiding this comment

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

isEmpty也根据isNativeStaticStyle走不同逻辑吧

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

已经修改

@mackwang112 mackwang112 merged commit 9d567bf into master Aug 26, 2025
6 checks passed
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