deanmcpherson / deanmcpherson/react-native-sortable-listview

Cannot read property 'pageY' of undefined

Open
#160 3 comments 2 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
909
Forks
225
PR merge metrics
No merged PRs in 30d

Description

Sometimes this unhandled exception occurs on tapping on a sortable item, if I have `moveOnPressIn` set:

```
Unhandled JS Exception: TypeError: Cannot read property 'pageY' of undefined

This error is located at:
in SortRow (at index.js:418)
in RCTView (at View.js:60)
in View (at index.js:487)
in SortableListView (created by EditFrame)
in RCTView (at View.js:60)
in View (created by EditFrame)
in RCTView (at View.js:60)
in View (created by EditFrame)
in RCTView (at View.js:60)
in View (created by EditFrame)
in RCTView (at View.js:60)
in View (created by EditFrame)
in EditFrame (created by ModuleEdit)
in ModuleEdit (created by Connect(ModuleEdit))
in Connect(ModuleEdit) (at SceneView.js:17)
in SceneView (at CardStack.js:466)
in RCTView (at View.js:60)
in View (at createAnimatedComponent.js:154)
in AnimatedComponent (at Card.js:12)
in Card (at PointerEventsContainer.js:39)
in Container (at CardStack.js:498)
in RCTView (at View.js:60)
in View (at CardStack.js:414)
in RCTView (at View.js:60)
in View (at CardStack.js:413)
in CardStack (at CardStackTransitioner.js:67)
in RCTView (at View.js:60)
in View (at Transitioner.js:142)
in Transitioner (at CardStackTransitioner.js:19)
in CardStackTransitioner (at StackNavigator.js:41)
in Unknown (at createNavigator.js:13)
in Navigator (at createNavigationContainer.js:226)
in NavigationContainer (at SceneView.js:17)
in SceneView (at DrawerScreen.js:21)
in DrawerScreen (at withCachedChildNavigation.js:69)
in withCachedChildNavigation(DrawerScreen) (at DrawerNavigator.js:71)
in Unknown (at createNavigator.js:13)
in Navigator (at DrawerView.js:178)
in RCTView (at View.js:60)
in View (at createAnimatedComponent.js:154)
in AnimatedComponent (created by DrawerLayout)
in RCTView (at View.js:60)
in View (created by DrawerLayout)
in DrawerLayout (at DrawerView.js:158)
in DrawerView (at DrawerNavigator.js:88)
in Unknown (at createNavigator.js:13)
in Navigator (at createNavigationContainer.js:226)
in NavigationContainer (created by PrimaryNav)
in PrimaryNav (created by Connect(PrimaryNav))
in Connect(PrimaryNav) (created by App)
in RCTView (at View.js:60)
in View (at Root.js:13)
in Root (at connectStyle.js:384)
in Styled(Root) (created by App)
in PersistGate (created by App)
in Provider (created by App)
in App (at renderApplication.js:33)
in RCTView (at View.js:60)
in View (at AppContainer.js:102)
in RCTView (at View.js:60)
in View (at AppContainer.js:122)
in AppContainer (at renderApplication.js:32)
```

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at index.js around SortRow line 418, where the reported pageY error occurs, and review the sortable-item tap path when moveOnPressIn is enabled. Reproduce the exception by tapping a sortable item with that setting; done means the unhandled pageY error no longer occurs.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react-native
Domain
mobile
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.