mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2025-10-16 12:05:38 +00:00
Fixes the issue when you register blocks with `block.json` in your theme. There is no longer an assets's URL error because it resolves correctly in relation to the theme where it is located. Props fabiankaegy, ocean90, whoisnegrello, audrasjb, peterwilsoncc, Fixes #54647, #55513. git-svn-id: https://develop.svn.wordpress.org/trunk@53091 602fd350-edb4-49c9-b593-d223f7449a82
8 lines
150 B
PHP
8 lines
150 B
PHP
<?php
|
|
|
|
add_action( 'init', 'register_theme_blocks' );
|
|
|
|
function register_theme_blocks() {
|
|
register_block_type( __DIR__ . 'blocks/example-block' );
|
|
}
|