Created
July 29, 2018 19:46
-
-
Save mintplugins/d1640296e31ea8a3b43610c15c5dcc5a to your computer and use it in GitHub Desktop.
Static JSX Gutenberg Block
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { __ } = wp.i18n; | |
const { registerBlockType } = wp.blocks; | |
registerBlockType( 'my-custom-gutenberg-block/static-jsx-example', { | |
title: __( 'Static Block Example with JSX' ), | |
icon: 'lock', | |
category: 'common', | |
edit() { | |
return ( | |
<p>Static block example built with JSX.</p> | |
); | |
}, | |
save() { | |
return ( | |
<p>Static block example built with JSX.</p> | |
); | |
}, | |
} ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment