react-native-component / react-native-smart-sortable-sudoku-grid

A smart sortable sudoku grid for React Native apps
MIT License
107 stars 42 forks source link

disappear cells when i drag too fast and sometimes the app crash #3

Open kelvinlemus opened 7 years ago

kelvinlemus commented 7 years ago

this happens at the end of the event when i drag too fast

and in other case the app crash but i can not replicate the error yet flatten-children null-is-not-an-object

i want to help, can you tell me how can i do that ?

cyqresig commented 7 years ago

Dear kelvinlemus. Can u tell me more about ur environment sth like react-native version, device and so on? And did it happen on device with release mode?

kelvinlemus commented 7 years ago

i'm using:

this happens in development, the app is not pruduction ready

i think that _sortCells had not finished and _getTouchCell did not return cell or something like that

which part of code do you think i can look ?

and thanks for answering

cyqresig commented 7 years ago

I think it is a bug with component's prop 'ref' in debug mode on android emulator. It won't happen in release mode on device, so need not to fix the codes,

kelvinlemus commented 7 years ago

I'm using the example code and it works fine, but when i add more cells (36) the cells do not position correctly. And i have tried this on physical device (android 5.1) and happens the same.

i have found the call of _sortDataSourceat the end of _onTouchEnd is not necessary, the view keep updated https://github.com/react-native-component/react-native-smart-sortable-sudoku-grid/blob/master/SortableSudokuGrid.js#L319