Areas
Introduction
Areas are static drop-zones for blocks. Areas are great for managing blocks that display in your footer, sidebar, below a post, etc.
Creating Areas
You can create areas through the control panel and assign blocks to them there as well.
Creating areas programmatically is the same as creating any other stream:
use Anomaly\BlocksModule\Area\Contract\AreaRepositoryInterface;
public function example(AreaRepositoryInterface $areas) {
$this->areas->create(
[
'en' => [
'name' => 'Footer',
'description' => 'Add blocks here to display in your footer.',
],
'slug' => 'footer',
]
);
}