Opened 18 months ago
Last modified 17 months ago
#61978 new enhancement
Managing Dynamic Search, Category Filtering, and Pagination for Bulk Patterns
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Milestone: | Awaiting Review | Priority: | normal |
| Severity: | normal | Version: | 6.0 |
| Component: | REST API | Keywords: | |
| Focuses: | rest-api, performance | Cc: |
Description
I noticed that the get_collection_params method and query filter function are not present in the get_items method of the WP_REST_Block_Patterns_Controller class. How can this be effective when registering a large number of patterns? Relying solely on the init hook and register_block_pattern may negatively impact site performance. There should be an alternative approach to registering patterns that can better handle dynamic search, filtering, and pagination for a large volume of patterns.
Change History (2)
#2
@
17 months ago
- Type changed from defect (bug) to enhancement
Hello @hellofromTonya,
Thank you for your reply! I apologize, but upon further reflection, I realize I may have submitted the ticket incorrectly. This issue is more of an enhancement for future WordPress updates.
As WordPress dives deeper into the age of block patterns, we can expect a rise in developers creating and sharing their pattern libraries. However, there seems to be a lack of built-in tools for efficiently managing large collections of patterns. Currently, relying solely on the init hook and register_block_pattern function for pattern registration could negatively impact site performance.
This highlights the need for a more robust system for managing patterns within WordPress.
Hello @codersantosh,
Welcome back to WordPress Core's Trac.
I'm doing triage for 6.6.x cycle. No changes were made in this class in 6.6.1.
The class was introduced in 6.0.0. The
get_items()method signature has not changed since first introduced via [53152].Updating the
Versionto 6.0.0 to reflect when the method's signature was introduced.Also lowering the severity to
normal, given its not causing "major" errors / site breakages.