Skip to content

Use ReactNode type for children props#2385

Merged
pascalbaljet merged 1 commit into
inertiajs:masterfrom
chack1172:fix/react-children-types
Jul 31, 2025
Merged

Use ReactNode type for children props#2385
pascalbaljet merged 1 commit into
inertiajs:masterfrom
chack1172:fix/react-children-types

Conversation

@chack1172

Copy link
Copy Markdown
Contributor

ReactNode includes all the possible renderable types. The current definitions misses some types, this will throw type error for example:

<Deferred data="options" fallback={<span>Fallback</span>}
<div>first line</div>
<div>second line</div>
</Deferred>

@chack1172
chack1172 force-pushed the fix/react-children-types branch from d9fd02f to ee636ce Compare June 18, 2025 21:07
@pascalbaljet pascalbaljet added the typescript Related to TypeScript implementation label Jul 29, 2025
@pascalbaljet
pascalbaljet merged commit a646842 into inertiajs:master Jul 31, 2025
6 checks passed
@pascalbaljet

Copy link
Copy Markdown
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

typescript Related to TypeScript implementation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants