mirror of
https://fast.feibisi.com/https://github.com/wp-cli/scaffold-command.git
synced 2026-07-28 13:00:03 +08:00
36 lines
736 B
Text
36 lines
736 B
Text
( function( wp ) {
|
|
var el = wp.element.createElement;
|
|
var __ = wp.i18n.__;
|
|
|
|
// Visit https://wordpress.org/gutenberg/handbook/block-api/ to learn about Block API
|
|
wp.blocks.registerBlockType( '{{namespace}}/{{slug}}', {
|
|
title: __( '{{title_ucfirst}}', '{{textdomain}}' ),
|
|
|
|
{{#dashicon}}
|
|
icon: '{{dashicon}}',
|
|
|
|
{{/dashicon}}
|
|
category: '{{category}}',
|
|
|
|
// Remove to make block editable in HTML mode.
|
|
supportHTML: false,
|
|
|
|
edit: function( props ) {
|
|
return el(
|
|
'p',
|
|
{ className: props.className },
|
|
__( 'Replace with your content!', '{{textdomain}}' )
|
|
);
|
|
},
|
|
|
|
save: function() {
|
|
return el(
|
|
'p',
|
|
{},
|
|
__( 'Replace with your content!', '{{textdomain}}' )
|
|
);
|
|
}
|
|
} );
|
|
} )(
|
|
window.wp
|
|
);
|