Learn how to build a custom block- using only other core blocks. Why? WordPress core already offers blocks for most common HTML elements- paragraphs, headings, images, divs, and more. Instead of starting from scratch on your next custom block, consider building it using the “InnerBlocks” feature to save time and offer a better user experience.
In this tutorial, we’ll build a custom carousel block using only the Cover block that comes built into WordPress. We’ll register our custom block type and write some JavaScript to get it running. Along the way, we’ll discuss the pros and cons of using the InnerBlocks method of block building.