// grab all block types const types = wp.blocks.getBlockTypes(); // filter to just the core blocks const core_blocks = types.filter( type => type.name.startsWith( 'core/' ) ); // grab just the names const block_names = core_blocks.map( type => type.name ); // display in the console console.log( block_names );