marudy / react-native-responsive-screen

Make React Native views responsive for all devices with the use of 2 simple methods
MIT License
1.56k stars 142 forks source link

will RNRS support functional components anytime soon? this.setState undefined error is still here #92

Open sammysium opened 3 years ago

sammysium commented 3 years ago

I have seen two issues, at least, #65 and #82 . My component is functional but the View is not responsive to orientation change. Using the listners causes this.setState is not defined. Given a couple of PR attempts that have not yet been merged in yet, is there a plan to handle this issue please? It is sort of a deal breaker for such a great library.

gregfenton commented 3 years ago

My pull request adds support for functional components and a working example: https://github.com/marudy/react-native-responsive-screen/pull/83

Greg Fenton.

On Wed., Dec. 23, 2020, 08:56 sammysium, notifications@github.com wrote:

I have seen two issues, at least, #65 https://github.com/marudy/react-native-responsive-screen/issues/65 and

82 https://github.com/marudy/react-native-responsive-screen/issues/82

. My component is functional but the View is not responsive to orientation change. Using the listners causes this.setState is not defined. Given a couple of PR attempts that have not yet been merged in yet, is there a plan to handle this issue please? It is sort of a deal breaker for such a great library.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/marudy/react-native-responsive-screen/issues/92, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABBUCB3PSFWBM3YVVJ5OPBLSWHZIVANCNFSM4VHATUKQ .

sammysium commented 3 years ago

@gregfenton i saw it. will it be merged or we gotta stick to your PR?

gregfenton commented 3 years ago

I had missed that @marudy is asking for maintenance helpers: https://github.com/marudy/react-native-responsive-screen/commit/94a632049d27018ac9786cee8b5e03d6d87813a8

Greg Fenton.

On Wed., Dec. 23, 2020, 10:48 sammysium, notifications@github.com wrote:

@gregfenton https://github.com/gregfenton i saw it. will it be merged or we gotta stick to your PR?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/marudy/react-native-responsive-screen/issues/92#issuecomment-750358228, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABBUCB2DCPSGOIIPM5MN3WLSWIGLVANCNFSM4VHATUKQ .