Make WordPress Core

Opened 10 months ago

Closed 10 months ago

Last modified 10 months ago

#60447 closed defect (bug) (fixed)

Block Bindings API: Create WP_Block_Bindings_Source class

Reported by: czapla's profile czapla Owned by: gziolo's profile gziolo
Milestone: 6.5 Priority: normal
Severity: normal Version:
Component: Editor Keywords: has-patch has-unit-tests
Focuses: Cc:

Description

This change refactors the array of Block Binding sources into its own class.

Change History (3)

This ticket was mentioned in PR #6042 on WordPress/wordpress-develop by @czapla.


10 months ago
#1

This PR refactors the array of Block Binding sources into its own WP_Block_Bindings_Source class.

This change was previously discussed in https://github.com/WordPress/gutenberg/issues/53300#issuecomment-1926572096

### Reasons for this change

  • Having a well-defined class for the sources makes it clearer what types are expected to be passed.
  • It makes the implementation more flexible for future changes.

#2 @gziolo
10 months ago

  • Owner set to gziolo
  • Resolution set to fixed
  • Status changed from new to closed

In 57562:

Editor: Introduce WP_Block_Bindings_Source class

Abstracts the block bindings source array into a well-defined object.

Fixes #60447.
See #60282.
Follow-up [57373].
Props czapla, santosguillamot, gziolo.

Note: See TracTickets for help on using tickets.