Skip to content
This repository was archived by the owner on Sep 21, 2026. It is now read-only.

Fix react keys warning when using dangerouslyDisableWhitespaceCollapsing - #563

Closed
eVoloshchak wants to merge 1 commit into
meliorence:masterfrom
eVoloshchak:eVoloshchak_reactKeysWarning
Closed

eVoloshchak wants to merge 1 commit into
meliorence:masterfrom
eVoloshchak:eVoloshchak_reactKeysWarning

Conversation

@eVoloshchak

Copy link
Copy Markdown

Checks

Description

Fixed issue: #562

I've read section about regression tests in Contributor's Guide, but not sure how to implement the test, since we essentially need to check for the absence of the yellow box warning.

@samrod samrod left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Can we have this merged ASAP please?

@jsamr

jsamr commented May 14, 2022

Copy link
Copy Markdown
Collaborator

@eVoloshchak Thank you for your proposition! The real issue is that dangerously (which means in this context: not really tested) disabling whitespace collapsing would cause @native-html/transient-render-engine to produce a faulty tree in certain situations, where indexes are not reflecting real position. Hence, this should be fixed in this repository instead of implementing a hack around here: https://github.com/native-html/core/tree/master/packages/transient-render-engine.

As a side note regarding using this not-so-recommended prop, in most of the cases you'll be better off with a global style which sets white-space: pre.

@eVoloshchak

Copy link
Copy Markdown
Author

@eVoloshchak Thank you for your proposition! The real issue is that dangerously (which means in this context: not really tested) disabling whitespace collapsing would cause @native-html/transient-render-engine to produce a faulty tree in certain situations, where indexes are not reflecting real position. Hence, this should be fixed in this repository instead of implementing a hack around here: https://github.com/native-html/core/tree/master/packages/transient-render-engine.

As a side note regarding using this not-so-recommended prop, in most of the cases you'll be better off with a global style which sets white-space: pre.

Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants