Skip to content

Commit 7383712

Browse files
committed
upgraded Example project to react-native 0.31
1 parent 48bc885 commit 7383712

File tree

6 files changed

+45
-29
lines changed

6 files changed

+45
-29
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
node_modules
22
npm-debug.log
3+
*.iml

Example/TextInputEffectsExample.js

+6
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@ import {
2222
Fumi,
2323
} from 'react-native-textinput-effects';
2424

25+
// eslint-disable-next-line no-console
26+
console.ignoredYellowBox = [
27+
// https://github.com/facebook/react-native/issues/9093
28+
'Warning: You are manually calling a React.PropTypes validation',
29+
];
30+
2531
export default class TextInputEffectsExample extends Component {
2632

2733
render() {

Example/android/app/src/main/AndroidManifest.xml

+1
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
android:targetSdkVersion="22" />
1212

1313
<application
14+
android:name=".MainApplication"
1415
android:allowBackup="true"
1516
android:label="@string/app_name"
1617
android:icon="@mipmap/ic_launcher"
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,6 @@
11
package com.textinputeffects;
22

33
import com.facebook.react.ReactActivity;
4-
import com.oblador.vectoricons.VectorIconsPackage;
5-
import com.facebook.react.ReactPackage;
6-
import com.facebook.react.shell.MainReactPackage;
7-
8-
import java.util.Arrays;
9-
import java.util.List;
104

115
public class MainActivity extends ReactActivity {
126

@@ -18,25 +12,4 @@ public class MainActivity extends ReactActivity {
1812
protected String getMainComponentName() {
1913
return "TextInputEffects";
2014
}
21-
22-
/**
23-
* Returns whether dev mode should be enabled.
24-
* This enables e.g. the dev menu.
25-
*/
26-
@Override
27-
protected boolean getUseDeveloperSupport() {
28-
return BuildConfig.DEBUG;
29-
}
30-
31-
/**
32-
* A list of packages used by the app. If the app uses additional views
33-
* or modules besides the default ones, add more packages here.
34-
*/
35-
@Override
36-
protected List<ReactPackage> getPackages() {
37-
return Arrays.<ReactPackage>asList(
38-
new MainReactPackage(),
39-
new VectorIconsPackage()
40-
);
41-
}
4215
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
package com.textinputeffects;
2+
3+
import android.app.Application;
4+
import android.util.Log;
5+
6+
import com.facebook.react.ReactApplication;
7+
import com.facebook.react.ReactInstanceManager;
8+
import com.facebook.react.ReactNativeHost;
9+
import com.facebook.react.ReactPackage;
10+
import com.facebook.react.shell.MainReactPackage;
11+
12+
import java.util.Arrays;
13+
import java.util.List;
14+
15+
public class MainApplication extends Application implements ReactApplication {
16+
17+
private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
18+
@Override
19+
protected boolean getUseDeveloperSupport() {
20+
return BuildConfig.DEBUG;
21+
}
22+
23+
@Override
24+
protected List<ReactPackage> getPackages() {
25+
return Arrays.<ReactPackage>asList(
26+
new MainReactPackage()
27+
);
28+
}
29+
};
30+
31+
@Override
32+
public ReactNativeHost getReactNativeHost() {
33+
return mReactNativeHost;
34+
}
35+
}

Example/package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
"start": "node node_modules/react-native/local-cli/cli.js start"
77
},
88
"dependencies": {
9-
"react": "^15.1.0",
10-
"react-native": "^0.28.0",
9+
"react": "^15.2.1",
10+
"react-native": "^0.31.0",
1111
"react-native-textinput-effects": "file:../",
1212
"react-native-vector-icons": "^2.0.3"
1313
}

0 commit comments

Comments
 (0)