fix: could not fing view for tag warning#1379
Merged
kirillzyusko merged 1 commit intomainfrom Mar 18, 2026
Merged
Conversation
dda1790 to
d74f3c8
Compare
Contributor
📊 Package size report
|
Contributor
|
|
The latest updates on your projects. Learn more about Argos notifications ↗︎
|
|
This was tearing my hair out! After seeing your tweet, I've updated to 1.21 to implement chat and whoa I thought I did something!! So glad I checked the PR! Thank you as always. |
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.
📜 Description
Silent
could not fing view for tagwarning forKeyboardAwareScrollView(similarly how it works forKeyboardAvoidingViewnow).💡 Motivation and Context
This issue got introduced after #1352 (which was based on #1346)
In certain cases
onLayoutmay be triggered but view may be not laid out yet (if you use it withreact-native-pagerlazy). Since changes in #1352 were purely additional (we try to understand the position of element on the screen, but before these changes we always assumed we were in the top of the screen) I decided to wrap it for now intry/catchblock.Silenting error is not a correct fix, but this is the best what we can do now - we will not spam logs when devs update the package (in #1346 we also used
catchblock), but yes, in certain cases detection of top border will not work (and it didn't work before, so it's fair enough to silent the error).Closes #1375
📢 Changelog
JS
try/catchblock;🤔 How Has This Been Tested?
Tested via e2e tests, I didn't test changes manually because I don't have a repro.
📝 Checklist