Using just three filters, we’ll add a few custom fields to the core “Button” block in WordPress that will update the button’s content on the front end. We’ll use a little bit of JavaScript, including WordPress/scripts and WordPress/components, as well as the new WP_HTML_Tag_Processor class in PHP.
👉 Code: https://github.com/bacoords/example-query-loop-button
👉 Block Filters: https://developer.wordpress.org/block-editor/reference-guides/filters/block-filters/
👉 SlotFill: https://developer.wordpress.org/block-editor/reference-guides/components/slot-fill/
👉 Gutenberg Storybook: https://wordpress.github.io/gutenberg/?path=/docs/docs-introduction–page
Leave a Reply