Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using the Block Bindings editor API (JS) in WP 6.7 #317

Open
justintadlock opened this issue Oct 4, 2024 · 2 comments
Open

Using the Block Bindings editor API (JS) in WP 6.7 #317

justintadlock opened this issue Oct 4, 2024 · 2 comments

Comments

@justintadlock
Copy link

WordPress 6.7 exposes a partial set of JS-based editor functions for working with Block Bindings: WordPress/gutenberg#65713

  • registerBlockBindingsSource: to register a source in the client.
  • unregisterBlockBindingsSource: to unregister an existing source.
  • getBlockBindingsSource: to get a specific registered source and its properties.
  • getBlockBindingsSources: to get all the registered sources in the client.

These are now stable, public functions for theme and plugin authors to extend how Block Bindings work in their projects, especially custom Block Binding sources. I'm proposing a tutorial that walks developers through using these APIs to manipulate bindings in the editor.

There is an additional getFieldsList property that will also be public in the Gutenberg plugin only, which could also be a showcase of what's to come in the future.

@justintadlock
Copy link
Author

The "create ticket from discussion" feature on GitHub seems to broken (at least for me) right now, so I just copied this over from: #316

@WordPress WordPress locked and limited conversation to collaborators Oct 8, 2024
@WordPress WordPress unlocked this conversation Oct 8, 2024
@justintadlock justintadlock self-assigned this Oct 8, 2024
@justintadlock
Copy link
Author

I'm working on this one here: https://docs.google.com/document/d/17o20lmRBxbak8hegX-RmtpKjS2hKlyyc18mbaYR4IWs/edit?usp=sharing

Code examples are up with a rough idea of an outline. Now it's time to fill in all the blank space with words!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: In Progress
Development

No branches or pull requests

1 participant