Skip to content

Commit 8ee5015

Browse files
hoyajigicharpeni
authored andcommitted
alert is in the Alert module (facebook#423)
I think this was a mistake
1 parent 3e73402 commit 8ee5015

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/modal.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ The Modal component is a simple way to present content above an enclosing view.
99
1010
```javascript
1111
import React, {Component} from 'react';
12-
import {Modal, Text, TouchableHighlight, View} from 'react-native';
12+
import {Modal, Text, TouchableHighlight, View, Alert} from 'react-native';
1313

1414
class ModalExample extends Component {
1515
state = {
@@ -28,7 +28,7 @@ class ModalExample extends Component {
2828
transparent={false}
2929
visible={this.state.modalVisible}
3030
onRequestClose={() => {
31-
alert('Modal has been closed.');
31+
Alert.alert('Modal has been closed.');
3232
}}>
3333
<View style={{marginTop: 22}}>
3434
<View>

0 commit comments

Comments
 (0)