mirror of
https://github.com/zoriya/react-native-web.git
synced 2026-05-24 15:18:19 +00:00
[fix] Flow type checking and annotations
Fixes dozens of Flow errors; adds type annotations; marks more files for Flow type checking. Fixes a bug in 'AppState'. 15 Flow errors remaining. Several React Native files are still not type checked (e.g., PanResponder, Touchables) Ref #465
This commit is contained in:
@@ -188,7 +188,7 @@ const GameEndOverlay = createReactClass({
|
||||
|
||||
const TicTacToeApp = createReactClass({
|
||||
getInitialState() {
|
||||
return { board: new Board(), player: 1 }
|
||||
return { board: new Board(), player: 1 };
|
||||
},
|
||||
|
||||
restartGame() {
|
||||
@@ -214,7 +214,11 @@ const TicTacToeApp = createReactClass({
|
||||
const rows = this.state.board.grid.map((cells, row) => (
|
||||
<View key={'row' + row} style={styles.row}>
|
||||
{cells.map((player, col) => (
|
||||
<Cell key={'cell' + col} onPress={this.handleCellPress.bind(this, row, col)} player={player} />
|
||||
<Cell
|
||||
key={'cell' + col}
|
||||
onPress={this.handleCellPress.bind(this, row, col)}
|
||||
player={player}
|
||||
/>
|
||||
))}
|
||||
</View>
|
||||
));
|
||||
|
||||
Reference in New Issue
Block a user