figuren-theater / label-printing

Create printable labels with blocks
GNU General Public License v3.0
2 stars 1 forks source link

Create a local-only reusable-block or a ‚reusable-block light‘ #12

Open carstingaxion opened 1 year ago

carstingaxion commented 1 year ago

We need a dynamic block that works very similar to a normal reusable-block or template-part, with the difference that it’s content - aka its innerBlocks - is coming from another block within the same post, not another post itself.

In PHP this is easy done like this and would be fine to use as the blocks render_callback for the frontend: ….

But by avoiding the use of the <ServerSideRender>component because of its flashy rendering, how to do it with JS and using other Gutenberg packages?

I’ve looked into the following, which looked promising:

—-