Edit Post: Fix suppressed errors in Layout component#77940
Conversation
| const getAriaValueNow = ( height ) => | ||
| Math.round( ( ( height - min ) / ( max - min ) ) * 100 ); | ||
| const persistIsOpen = ( to = ! isOpen ) => | ||
| setPreference( 'core/edit-post', 'metaBoxesMainIsOpen', to ); |
There was a problem hiding this comment.
Error: Methods can't be used before their declaration.
| { ...navigateRegionsProps } | ||
| ref={ navigateRegionsProps.ref } | ||
| > | ||
| <div { ...navigateRegionsProps }> |
There was a problem hiding this comment.
Error: A false position for calling ref during render. The navigateRegionsProps only contains three values, so we can just use destruction. I couldn't find a reason why this pattern was used in #63611.
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
|
Size Change: -19 B (0%) Total Size: 7.91 MB 📦 View Changed
ℹ️ View Unchanged
|
|
Flaky tests detected in a8557b4. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/25367534811
|
What?
PR fixes a couple of suppressed errors after the recent React ESLint rule update. I was just in the area and decided to push the fix.
Testing Instructions
CI checks are passing.
Use of AI Tools
None.