Call to a member function partiallyRender() on null" with partiallyRenderComponentsAfterStateUpdated

Hello everyone,

I'm trying to use the new partiallyRenderComponentsAfterStateUpdated method in my Filament v4 form, but I'm encountering a Call to a member function partiallyRender() on null error.

My goal is to conditionally show a FileUpload or TextInput field based on the value of a Select field, and use partial rendering for performance.

Here is a simplified version of my code:

Section::make(__('File Configuration'))
    ->schema([
        Select::make('file_type')
            ->live()
            ->options(...)
            ->required()
            ->partiallyRenderComponentsAfterStateUpdated(['file_path', 'asset_path']),

        FileUpload::make('file_path')
            ->visible(fn($get) => $get('file_type') === 'file'),

        TextInput::make('asset_path')
            ->visible(fn($get) => $get('file_type') === 'asset'),
    ]),

My questions are:

Is there a known issue or bug with partiallyRenderComponentsAfterStateUpdated that would cause this null error?

Am I missing a required setup to use this feature correctly?

Is there a specific way this method should be called within a Section or on a Select component?
Was this page helpful?