publish \vendor\filament\forms\src\Components\CheckboxList.php #9567
-
|
It is possible to publish one of the \vendor\filament\forms\src\Components files outside the vendor folder to customize it, specifically I need to make changes to CheckboxList.php but I require that it not be overwritten when the filament version is updated. thanks in advanced. |
Beta Was this translation helpful? Give feedback.
Answered by
leandrocfe
Nov 9, 2023
Replies: 1 comment 1 reply
-
|
Create a custom class in your app //app/Filament/Forms/Components/CheckboxList.php
namespace App\Filament\Forms\Components;
use Filament\Forms\Components\CheckboxList as BaseCheckboxList;
class CheckboxList extends BaseCheckboxList
{
protected string $view = 'filament.forms.components.checkbox-list';
}Create a custom view in Copy the original content from the vendor and edit what you want. Use in your form \App\Filament\Forms\CheckboxList::make('field') |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
juangdnar
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Create a custom class in your app
Create a custom view in
resources/views/filament/forms/components/checkbox-list.blade.phpCopy the original content from the vendor and edit what you want.
Use in your form