Skip to main content

Create a block

A block can best be compared to a section tag in html. The <section> tag is often used to organize the content of a webpage into logical sections, making it easier for users to navigate and understand the content. Same goes for blocks. They are individual sections that can be added to a page within Instant Commerce.

Once your project is running, you have the option to create a block. Creating new block is done using the generate command, followed by a name for the block. Generate will create local files needed to start developing a block.

Generate

Terminal
instant generate block <name>

Add

The add command adds the block to the current organisation which is connected to your account. If your account has multiple organisations connected to it, Instant will prompt you to select which organisation the block belongs to.

Terminal
instant add [blocknames..]