Skip to content

Commit ecbc475

Browse files
committed
uncommented web line
1 parent 5b4833a commit ecbc475

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

App.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,18 @@ import {
66
} from 'react-native';
77

88
// Flip this bool!
9-
const someCondition = true;
9+
const someCondition = false;
1010

1111
class App extends React.Component {
1212
state = { webValue: null, nativeValue: null }
1313

1414
componentDidMount() {
1515
if(someCondition) {
1616
import('./dynamic-module').then(module => {
17+
// This should work fine in RN
1718
module.reactNative().then(val => this.setState({ nativeValue: val[1] }));
1819
// Following line generates warnings of no reference to localstorage
19-
// this.setState({ webValue: module.reactWeb() });
20+
this.setState({ webValue: module.reactWeb() });
2021
})
2122
}
2223
}
@@ -25,7 +26,6 @@ class App extends React.Component {
2526
return (
2627
<Fragment>
2728
<SafeAreaView>
28-
<Text> Hey There! This is a sample app! </Text>
2929
<Text>webValue: { this.state.webValue || 'null' }</Text>
3030
<Text>nativeValue: { this.state.nativeValue || 'null' }</Text>
3131
</SafeAreaView>

0 commit comments

Comments
 (0)