Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resolve react/prop-types lint warnings for forms/src/index.tsx #4135

Closed
1 task done
thedavidprice opened this issue Jan 13, 2022 · 4 comments · Fixed by #4176 or #3762
Closed
1 task done

Resolve react/prop-types lint warnings for forms/src/index.tsx #4135

thedavidprice opened this issue Jan 13, 2022 · 4 comments · Fixed by #4176 or #3762
Assignees

Comments

@thedavidprice
Copy link
Contributor

thedavidprice commented Jan 13, 2022

Update

This is due to an upstream issue with eslint-plugin-react. See: jsx-eslint/eslint-plugin-react#3140

A temporary workaround has been applied via #4176

Next Steps
Once the upstream issue is resolved: (EDIT by Aditya - Workaround in #3762)

Original

We're getting lint warnings that should be resolved for v1:

➜  redwoodjs-redwood git:(main) ✗ yarn lint

/Users/price/Repos/redwoodjs-redwood/packages/forms/src/index.tsx
  336:7   warning  'config' is missing in props validation                                                react/prop-types
  337:7   warning  'error' is missing in props validation                                                 react/prop-types
  338:7   warning  'formMethods' is missing in props validation                                           react/prop-types
  339:7   warning  'onSubmit' is missing in props validation                                              react/prop-types
  358:25  warning  'error.graphQLErrors' is missing in props validation                                   react/prop-types
  358:43  warning  'error.graphQLErrors[].extensions' is missing in props validation                      react/prop-types
  358:55  warning  'error.graphQLErrors[].extensions.properties' is missing in props validation           react/prop-types
  358:67  warning  'error.graphQLErrors[].extensions.properties.messages' is missing in props validation  react/prop-types
  481:7   warning  'name' is missing in props validation                                                  react/prop-types
  482:7   warning  'id' is missing in props validation                                                    react/prop-types
  484:7   warning  'errorClassName' is missing in props validation                                        react/prop-types
  485:7   warning  'errorStyle' is missing in props validation                                            react/prop-types
  489:7   warning  'validation' is missing in props validation                                            react/prop-types
  490:7   warning  'onBlur' is missing in props validation                                                react/prop-types
  491:7   warning  'onChange' is missing in props validation                                              react/prop-types
  530:7   warning  'name' is missing in props validation                                                  react/prop-types
  531:7   warning  'id' is missing in props validation                                                    react/prop-types
  533:7   warning  'errorClassName' is missing in props validation                                        react/prop-types
  534:7   warning  'errorStyle' is missing in props validation                                            react/prop-types
  538:7   warning  'validation' is missing in props validation                                            react/prop-types
  539:7   warning  'onBlur' is missing in props validation                                                react/prop-types
  540:7   warning  'onChange' is missing in props validation                                              react/prop-types
  579:7   warning  'name' is missing in props validation                                                  react/prop-types
  580:7   warning  'id' is missing in props validation                                                    react/prop-types
  582:7   warning  'errorClassName' is missing in props validation                                        react/prop-types
  583:7   warning  'errorStyle' is missing in props validation                                            react/prop-types
  587:7   warning  'validation' is missing in props validation                                            react/prop-types
  588:7   warning  'onBlur' is missing in props validation                                                react/prop-types
  589:7   warning  'onChange' is missing in props validation                                              react/prop-types
  698:7   warning  'name' is missing in props validation                                                  react/prop-types
  699:7   warning  'id' is missing in props validation                                                    react/prop-types
  701:7   warning  'errorClassName' is missing in props validation                                        react/prop-types
  702:7   warning  'errorStyle' is missing in props validation                                            react/prop-types
  706:7   warning  'validation' is missing in props validation                                            react/prop-types
  707:7   warning  'onBlur' is missing in props validation                                                react/prop-types
  708:7   warning  'onChange' is missing in props validation                                              react/prop-types
  709:7   warning  'type' is missing in props validation                                                  react/prop-types

✖ 37 problems (0 errors, 37 warnings)

Related PR: #3762
Possible related underlying issue: jsx-eslint/eslint-plugin-react#3140

virtuoushub added a commit to virtuoushub/redwood that referenced this issue Jan 17, 2022
@virtuoushub
Copy link
Collaborator

@thedavidprice - is anyone currently fixing this? If not, I'll take a look.

virtuoushub added a commit to virtuoushub/redwood that referenced this issue Jan 18, 2022
virtuoushub added a commit to virtuoushub/redwood that referenced this issue Jan 18, 2022
callingmedic911 added a commit that referenced this issue Jan 18, 2022
* chore: add PropTypes

closes #4135

* Revert "chore: add PropTypes"

This reverts commit 3217ec6.

* chore: temporarily disable "react/prop-types"

closes #4135

Co-authored-by: Aditya Pandey <aditya@autospace.co>
@callingmedic911
Copy link
Collaborator

We disabled the lint rule in the file till it's fixed upstream (#4176). Keeping this issue open to track updates.

@thedavidprice
Copy link
Contributor Author

@callingmedic911 @jtoar I updated the OP with current status and next steps. Resolving this is not highest priority, but we do want to keep track of it. Since you're following the upstream Issue, I'll hand off the assignment to you @callingmedic911 Sound good?

@thedavidprice thedavidprice removed their assignment Jan 19, 2022
@callingmedic911
Copy link
Collaborator

Yep!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Archived
3 participants