inertia icon indicating copy to clipboard operation
inertia copied to clipboard

The children props is missing in InertiaHeadProps type for Head component

Open duongductrong opened this issue 2 years ago • 1 comments

Hi! 👋

Firstly, thanks for your work on this project! 🙂

Today I used patch-package to patch @inertiajs/[email protected] for the project I'm working on.

My pull request to fix this problem: https://github.com/inertiajs/inertia/pull/1326

Problem

Here is my problem:

https://i.imgur.com/YVYq8wu.png

Here is the diff that solved my problem:

diff --git a/node_modules/@inertiajs/inertia-react/index.d.ts b/node_modules/@inertiajs/inertia-react/index.d.ts
index 1a3a01b..18ae4f9 100755
--- a/node_modules/@inertiajs/inertia-react/index.d.ts
+++ b/node_modules/@inertiajs/inertia-react/index.d.ts
@@ -46,7 +46,8 @@ type InertiaLinkProps = BaseInertiaLinkProps & Omit<React.HTMLAttributes<HTMLEle
 type InertiaLink = React.FunctionComponent<InertiaLinkProps>
 	
 type InertiaHeadProps = {
-    title?: string
+    title?: string,
+    children?: React.ReactNode | React.ReactNode[];
 }
 
 type InertiaHead = React.FunctionComponent<InertiaHeadProps>

duongductrong avatar Oct 23 '22 15:10 duongductrong

Duplicate of #1253 & #1318.

benbjurstrom avatar Oct 27 '22 07:10 benbjurstrom

Hey! Thanks so much for your interest in Inertia.js and for sharing this issue/suggestion.

In an attempt to get on top of the issues and pull requests on this project I am going through all the older issues and PRs and closing them, as there's a decent chance that they have since been resolved or are simply not relevant any longer. My hope is that with a "clean slate" me and the other project maintainers will be able to better keep on top of issues and PRs moving forward.

Of course there's a chance that this issue is still relevant, and if that's the case feel free to simply submit a new issue. The only thing I ask is that you please include a super minimal reproduction of the issue as a Git repo. This makes it much easier for us to reproduce things on our end and ultimately fix it.

Really not trying to be dismissive here, I just need to find a way to get this project back into a state that I am able to maintain it. Hope that makes sense! ❤️

reinink avatar Jul 28 '23 01:07 reinink