I experienced some issues with the NPM when making changes in blocks or other elements as the changes were not working properly. Below is my gutenberg.php file:
function MyBlocks()
{
wp_register_script('blocks-js', get_template_directory_uri() . '/build/index.js', array('wp-blocks' , 'wp-editor' , 'wp-components' ));
register_block_type('yusuf/custom-cta', array('editor_script' => 'blocks-js'));
// register_block_type('yusuf/custom-pro', array('editor_script' => 'blocks-js'));
// register_block_type("yusuf/statics" , array('editor_script' => 'blocks-js'));
}
add_action('init', 'MyBlocks');
Even after commenting out the blocks, they still appear. I tried removing them from build/index.js as well, but they persist. I am curious to know why this issue occurred even though "NPM START" is running.