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

wrap React.PropsWithChildren #598

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

KAMEDAkyosuke
Copy link

@KAMEDAkyosuke KAMEDAkyosuke commented Apr 27, 2022

DefinitelyTyped/DefinitelyTyped@55dc209
children is removed on React 18

Thanks for submitting a pull request!

Please confirm you have linted your code and fixed any issues:

  • I ran yarn run fix on my PR and fixed any formatting issues

execute result. None were relevant to this fix.

% yarn run fix                           
yarn run v1.22.10
$ yarn run prettier && yarn run lint
$ prettier --write --loglevel=warn "**/*.js"
$ eslint . --ext .js

/path/to/react-native-swipe-list-view/SwipeListExample/example.js
  46:29  warning  Inline style: { backgroundColor: "mode === type ? 'grey' : 'white'" }  react-native/no-inline-styles

/path/to/react-native-swipe-list-view/SwipeListExample/examples/actions.js
   84:40  warning  Inline style: { backgroundColor: 'lightgreen' }  react-native/no-inline-styles
   91:44  warning  Inline style: { backgroundColor: 'lightgreen' }  react-native/no-inline-styles
  142:44  warning  Inline style: { backgroundColor: 'lightgreen' }  react-native/no-inline-styles
  159:29  warning  Inline style: { flex: 1 }                        react-native/no-inline-styles

/path/to/react-native-swipe-list-view/SwipeListExample/examples/per_row_config.js
  35:31  warning  Missing radix parameter  radix

/path/to/react-native-swipe-list-view/SwipeListExample/examples/sectionlist.js
  21:31  warning  '_' is already declared in the upper scope  no-shadow

/path/to/react-native-swipe-list-view/bin/dev.js
  42:44  warning  'err' is already declared in the upper scope  no-shadow

/path/to/react-native-swipe-list-view/components/SwipeRow.js
  634:28  warning  Inline style: { zIndex: 2 }  react-native/no-inline-styles
  648:28  warning  Inline style: { zIndex: 2 }  react-native/no-inline-styles

/path/to/react-native-swipe-list-view/types/flowtypes.js
  2:0  warning  Unexpected unlimited 'eslint-disable' comment. Specify some rule names to disable  eslint-comments/no-unlimited-disable
  2:1  warning  ESLint rules are disabled but never reported                                       eslint-comments/no-unused-disable

✖ 12 problems (0 errors, 12 warnings)

✨  Done in 4.68s.

Please provide information on what your PR achieves and any issues that it addresses:

DefinitelyTyped/DefinitelyTyped@55dc209
children is removed on React 18. So I add.

@DianaLaa
Copy link

Can this be merged please?

@vickycabrera
Copy link

I need it too u.u

@KAMEDAkyosuke
Copy link
Author

@jemise111 Would you review/merge/release this for us?

@lethib
Copy link

lethib commented Jan 19, 2023

I was also expecting this PR to be merged.

You can fix it on your own using patch-package !
Steps are also really well described in this video.

@vickycabrera
Copy link

I was also expecting this PR to be merged.

You can fix it on your own using patch-package ! Steps are also really well described in this video.

Thank you, I will try it while await for merge

@brunomacedo
Copy link

I also need this fix

Copy link
Contributor

@robwalkerco robwalkerco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not a maintainer or anything on this project, but I don't think this PR could be merged in its current state.

I've offered some suggestions to tidy up the import you added.

Comment on lines +1 to 2
import React = require('react');
import { Component } from 'react';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
import React = require('react');
import { Component } from 'react';
import { Component, PropsWithChildren } from 'react';

@@ -207,7 +208,7 @@ interface IPropsSwipeRow<T> {
useNativeDriver: boolean;
}

export class SwipeRow<T> extends Component<Partial<IPropsSwipeRow<T>>> {
export class SwipeRow<T> extends Component<Partial<React.PropsWithChildren<IPropsSwipeRow<T>>>> {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
export class SwipeRow<T> extends Component<Partial<React.PropsWithChildren<IPropsSwipeRow<T>>>> {
export class SwipeRow<T> extends Component<Partial<PropsWithChildren<IPropsSwipeRow<T>>>> {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants