When using getFieldList
with getInputProps
, warning of key
prop
#545
Unanswered
AkifumiSato
asked this question in
Q&A
Replies: 1 comment 1 reply
-
This is a warning only happens with Nextjs. It complains that you are spreading the result of getInputProps on the input element which does include a I have an idea that might allow Conform to remove the need of key in the future. But, for now, the only workaround is to specify the key manually as you did, but please specify the key provided by Conform instead of passing <input
{...getInputProps(memberFields.engineer, {
type: "checkbox",
})}
key={memberFields.engineer.key}
/> |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Describe the bug and the expected behavior
When
getFieldList
andgetInputProps
are used together, warn is displayed about thekey
prop being spread. I can work around this by explicitly settingkey={undefined}
, but it seems redundant.Conform version
v1.0.6
Steps to Reproduce the Bug or Issue
Add member
clickWhat browsers are you seeing the problem on?
No response
Screenshots or Videos
No response
Additional context
No response
Beta Was this translation helpful? Give feedback.
All reactions