danielbachhuber / gutenberg-migration-guide

Documents WordPress Classic Editor integration points and their Gutenberg equivalents
183 stars 14 forks source link

Example of "post_gallery" filter #16

Closed tyrann0us closed 5 years ago

tyrann0us commented 5 years ago

Please open a new issue to suggest additional examples of existing usage. — Post Gallery Filter

The plugin Slick Slider (https://github.com/tyrann0us/slick-slider) uses the post_gallery filter to turn native galleries into sliders: https://github.com/tyrann0us/slick-slider/blob/761477365a31a2947f65dd19e8ffbc818c0815d9/inc/class-output.php#L39-L47

Because of the missing filter the plugin ~does not work with Gutenberg~ cannot simply re-use it for websites that use the Block Editor, but the code has to be rewritten to use register_block_type()'s render_callback.

Disclaimer: I'm the author of this plugin.

danielbachhuber commented 5 years ago

Thanks for the report, @tyrann0us! Want to submit a pull request against the README with your example?

tyrann0us commented 5 years ago

See #19.