A sample repository for explaining how to build Gutenberg blocks.
For full explanation see blog post: https://mkaz.blog/misc/creating-a-gutenberg-block/
This block is more of an example, unlikely to be used in any real scenario. To install on your WordPress site. Download repository (or zip) and extract to your plugins directory and activate.
The block will show in the inserter within Gutenberg.
Note: You will also need the Gutenberg plugin installed.