fix: fix rendering failure when children is number 0#2549
Merged
liujuping merged 1 commit intoalibaba:developfrom Oct 12, 2023
Merged
fix: fix rendering failure when children is number 0#2549liujuping merged 1 commit intoalibaba:developfrom
liujuping merged 1 commit intoalibaba:developfrom
Conversation
rainke
reviewed
Oct 12, 2023
| */ | ||
| __createVirtualDom = (originalSchema: IPublicTypeNodeData | IPublicTypeNodeData[] | undefined, originalScope: any, parentInfo: INodeInfo, idx: string | number = ''): any => { | ||
| if (!originalSchema) { | ||
| if (originalSchema === null || originalSchema === undefined) { |
Contributor
There was a problem hiding this comment.
0 确实需要展示,但 false 和 NaN 需要展示吗
Contributor
Author
There was a problem hiding this comment.
我认为和react的处理机制保持一致吧,react中NaN会展示,false不会展示,如果可以的话我调整下代码。
Collaborator
There was a problem hiding this comment.
NaN 不需要展示。如果 originalSchema 传值是 false,我认为也是有必要展示的。这里不用和 react 的处理机制保持一致。
Contributor
Author
There was a problem hiding this comment.
0 确实需要展示,但 false 和 NaN 需要展示吗
已经被合并了😂 @rainke
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
修复当children值为数值0的时候无法正确渲染出来的问题。

