This is a small package that adds a few additional helper methods to Blocks for generating dynamic CSS class names. You can create class names for Blocks based on their component name in Storyblok, where they’re nested in the tree etc.
This package is a module for Laravel Storyblok
You can install the package via composer:
composer require riclep/laravel-storyblok-cssIt’s really simple to use, just add the trait to any blocks you want to create CSS classes for or alternatively the App\Storyblok\Block class.
namespace App\Storyblok;
use Riclep\Storyblok\Block as BaseBlock;
use Riclep\StoryblokCss\Traits\CssClasses;
class Block extends BaseBlock
{
use CssClasses;
}Please see CHANGELOG for more information what has changed recently.
Please see CONTRIBUTING for details.
If you discover any security related issues, please email ric@sirric.co.uk instead of using the issue tracker.
The MIT License (MIT). Please see License File for more information.
This package was generated using the Laravel Package Boilerplate.