Skip to content

Commit

Permalink
Support render Gutenberg blocks content
Browse files Browse the repository at this point in the history
  • Loading branch information
puleeno committed Jun 2, 2024
1 parent 21de1a6 commit ac5e59d
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/Page.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
<?php

/**
* Setup Jankx page (Theme system)
*/

namespace Jankx\Template;

use Jankx;
Expand Down Expand Up @@ -147,7 +149,11 @@ public function render()
do_action('jankx/template/page/content/before', $context, $this->templates);


echo $this->renderContent($engine);
if (!apply_filters('jankx/gutenberg/render/disabled', false, $this) && function_exists('jankx_is_support_block_template') && jankx_is_support_block_template()) {
echo get_the_block_template_html();
} else {
echo $this->renderContent($engine);
}

do_action('jankx/template/page/content/after', $context, $this->templates);

Expand Down

0 comments on commit ac5e59d

Please sign in to comment.