Using wp_localize_script for a block script
-
Hi,
I am developing a Gutenberg block using the @wordpress/create-block?tool. In the block.json I added a frontend script through
"viewScript": [ "file:./hwscript.js", "hbw-words-script" ],
Since register_block_type registers and enqueues the script using the data from block.json, how can I use wp_localize_script without enqueuing again the hwscript.js file?
Viewing 5 replies - 1 through 5 (of 5 total)
Viewing 5 replies - 1 through 5 (of 5 total)
- The topic ‘Using wp_localize_script for a block script’ is closed to new replies.