Skip to content

Commit

Permalink
fix(Error): fix Undefined is not an object (evaluating 'this.viewProp…
Browse files Browse the repository at this point in the history
…erties.width')
  • Loading branch information
Li Yongyu committed Nov 15, 2017
1 parent 7d54382 commit d04c669
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/FlatListItem.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ export default class FlatListItem extends React.PureComponent {
super(props);
this.state = {
visibility: true,
}
}

onLayout(evt) {
};
this.viewProperties = {
width: 0,
height: 0,
}
};
}

onLayout(evt) {
this.viewProperties.width = evt.nativeEvent.layout.width;
this.viewProperties.height = evt.nativeEvent.layout.height;
}
Expand Down

0 comments on commit d04c669

Please sign in to comment.