From 3d1bf44d535f99133dc7d82705c8bfe8e3ad38e8 Mon Sep 17 00:00:00 2001 From: codepuncher Date: Wed, 19 Jun 2024 09:07:06 +0100 Subject: [PATCH] feat: enqueue per-block assets --- src/Block.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Block.php b/src/Block.php index 035e654..6723a70 100644 --- a/src/Block.php +++ b/src/Block.php @@ -288,10 +288,15 @@ public function getBlockData(): array ]; } + public function getAssets(): void + { + } + public function init(): void { $block_data = $this->getBlockData(); $block_data['render_callback'] = [$this, 'renderBlockCallback']; + $block_data['enqueue_assets'] = $this->getAssets(); $fields = $this->getFields(); acf_register_block($block_data);