Skip to content

Commit

Permalink
[TodoMVC] update react-native
Browse files Browse the repository at this point in the history
  • Loading branch information
kassens committed Jul 13, 2017
1 parent 8479eef commit aeffe08
Show file tree
Hide file tree
Showing 5 changed files with 4,006 additions and 21 deletions.
1 change: 1 addition & 0 deletions TodoMVC/android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
<uses-permission android:name="android.permission.INTERNET" />

<application
android:name=".MainApplication"
android:allowBackup="true"
android:label="@string/app_name"
android:icon="@mipmap/ic_launcher"
Expand Down
19 changes: 0 additions & 19 deletions TodoMVC/android/app/src/main/java/com/todomvc/MainActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,4 @@ protected String getMainComponentName() {
return "TodoMVC";
}

/**
* Returns whether dev mode should be enabled.
* This enables e.g. the dev menu.
*/
@Override
protected boolean getUseDeveloperSupport() {
return BuildConfig.DEBUG;
}

/**
* A list of packages used by the app. If the app uses additional views
* or modules besides the default ones, add more packages here.
*/
@Override
protected List<ReactPackage> getPackages() {
return Arrays.<ReactPackage>asList(
new MainReactPackage()
);
}
}
35 changes: 35 additions & 0 deletions TodoMVC/android/app/src/main/java/com/todomvc/MainApplication.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
package com.todomvc;

import android.app.Application;
import android.util.Log;

import com.facebook.react.ReactApplication;
import com.facebook.react.ReactInstanceManager;
import com.facebook.react.ReactNativeHost;
import com.facebook.react.ReactPackage;
import com.facebook.react.shell.MainReactPackage;

import java.util.Arrays;
import java.util.List;

public class MainApplication extends Application implements ReactApplication {

private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
@Override
public boolean getUseDeveloperSupport() {
return BuildConfig.DEBUG;
}

@Override
protected List<ReactPackage> getPackages() {
return Arrays.<ReactPackage>asList(
new MainReactPackage()
);
}
};

@Override
public ReactNativeHost getReactNativeHost() {
return mReactNativeHost;
}
}
4 changes: 2 additions & 2 deletions TodoMVC/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
"express-graphql": "0.5.2",
"graphql": "0.6.0",
"graphql-relay": "0.4.2",
"react": "15.1.0",
"react-native": "0.28.0",
"react": "16.0.0-alpha.12",
"react-native": "^0.46.2",
"react-native-listitem": "1.0.5",
"react-native-swipeout": "git+https://github.com/magrinj/react-native-swipeout#403d973504b58ede25c137fb31b0eff7e03b0a66",
"react-relay": "0.9.2"
Expand Down
Loading

0 comments on commit aeffe08

Please sign in to comment.