Archived topic
Output Block Element via Shortcode
3 replies · Started by Clayton on February 25, 2022
Hey guys,
I know this is an unusual way to use a GP element but so many plugins still lack the ability to use the block editor. For example, if I want to use GenerateBlocks to build a mega menu that is being output via Max Mega Menu that isn't possible since Max Mega Menu doesn't allow you to use the Gutenberg builder.
My thought is that if it was possible to get a shortcode for a block element I could build whatever I want in Gutenberg and then output that element anywhere I want via Shortcode, which as I mentioned has much better support across plugins, etc.
Is this possible? Let me know what you think!
Hi Clayton,
I'm not sure whether it will work, but give this solution a try:
https://generatepress.com/forums/topic/hook/#post-1036765
I think I found a solution for this. Thanks
Glad you did :)