PHP code example of thiktak / filament-nested-builder-form
1. Go to this page and download the library: Download thiktak/filament-nested-builder-form library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
thiktak / filament-nested-builder-form example snippets
use Thiktak\FilamentNestedBuilderForm\Forms\Components\NestedBuilder;
use Thiktak\FilamentNestedBuilderForm\Forms\Components\NestedSubBuilder;
// ...
NestedBuilder::make('array_configuration')
// Add configuration to Builder & sub-builder
->nestedConfiguration(function (NestedSubBuilder $builder) {
// Apply only for the root level
$builder->blockNumbers($builder->getLevel() == 1);
// Apply for all others levels
$builder->columnSpanFull(); // full width
})
// Replace schema() by nestedSchema
->nestedSchema(function (NestedSubBuilder $builder) { // Closure is mandatory
return [
Block::make('group')
->schema([
Select::make('title')
->