capell-app/content-sections
A Laravel package from Capell for creating and managing reusable content sections across your application. Define structured content blocks once, then render them anywhere to keep layouts consistent and content easily editable through the CMS.
composer require capell-app/content-sections only makes sense after capell-app/capell is installed and booted — this package is a section-type library layered on Capell's blueprint/content model, not a CMS in itself. If you don't have Capell running, stop here and evaluate the core package first.php artisan migrate. Open config/content-sections.php before writing a line of code: the list of registered section types (hero, FAQ, pricing, team, comparison, …) is the map of what you get and the template for what you'll add.@foreach ($page->sections as $section)
@include('content-sections::sections.' . $section->type, ['data' => $section->data])
@endforeach
Keeping the loop trivial means a new section type never requires touching page templates — which is the entire value proposition.
resources/views/sections/hero.blade.php) rather than editing or re-publishing vendor Blade. If you must override a shipped type, do it via published views in your theme and record which ones you've overridden — see the gotchas.array, validate the item shape in the form/save path, and give the Blade view a defensive default ($data['items'] ?? []). Malformed JSON that reaches a view produces a confusing Blade error instead of a validation message.it('renders every registered section type', function (string $type) {
$section = Section::factory()->ofType($type)->create();
$this->get($section->page->url)->assertOk();
})->with(fn () => array_keys(config('content-sections.types')));
content-sections.php, php artisan config:clear locally and make sure deploys run config:cache. Verify the type is in the cached config, not just the file.$data['x'] exists.^1.0 (or ~1.0), read the commit diff rather than the release notes before bumping, and keep your custom types in your own namespace so a fork-and-replace stays a few hundred lines of work. Your per-type render test suite is the thing that makes those upgrades safe; build it before you have twenty section types in production.How can I help you explore Laravel packages today?