Localising a Block
There are 2 main issues in your code: As stated in my answer, the script handle format is <block name with slashes replaced with hypens>-editor-script, so because your block name is my-block/local, then the script handle is my-block-local-editor-script and not my-block-local-edit-script. The correct action name is wp_enqueue_scripts (note the “s”) and not wp_enqueue_script. However, wp_enqueue_scripts … Read more