Notes: Backport REST API changes in core#72554
Conversation
e6634c1 to
7323056
Compare
| @@ -1 +1 @@ | |||
| <?php | |||
There was a problem hiding this comment.
From my understanding, this file should be placed in lib/, not lib/compat/wordpres-6.9. The Notes feature will continue to be developed on Gutenberg, and the REST API itself is likely to be updated.
If a directory change is required, I will address it in this PR.
There was a problem hiding this comment.
I think it's a lib/compat/wordpres-6.9 for similar controller overrides. But you can check how other controllers are handled.
The only exception is theme.json and global styles, since Gutenberg needs to serve the latest version of it.
There was a problem hiding this comment.
If we need to extend the comments REST API for the 7.0 release, how would we go about doing that? Perhaps by creating another class in the lib/compat/wordpres-7.0 directory and overriding the entire method there? 🤔
There was a problem hiding this comment.
I think we usually just change directories then, or Controller_WP_7_0 extends Controller_WP_6_9 and only the latter is initialized.
The files for lib/ are rarely removed, while the compat files are cleaned up after we bump the minimum required version.
There was a problem hiding this comment.
or
Controller_WP_7_0 extends Controller_WP_6_9and only the latter is initialized.
I prefer this approach. Updated in dd0ce3d
|
Flaky tests detected in 84eb106. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/18716946979
|
|
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. |
|
Warning: Type of PR label mismatch To merge this PR, it requires exactly 1 label indicating the type of PR. Other labels are optional and not being checked here.
Read more about Type labels in Gutenberg. Don't worry if you don't have the required permissions to add labels; the PR reviewer should be able to help with the task. |
Related core PR:
What?
We've committed the Note feature to core. I'll incorporate any PHP code changes made during that feedback process into Gutenberg.
How?
Testing Instructions