Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Commit

Permalink
chore(deps): update Angular to 4.3.2 and React Native to 0.47.1 (#107)
Browse files Browse the repository at this point in the history
  • Loading branch information
marclaval committed Aug 3, 2017
1 parent a43bace commit 38773ee
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 19 deletions.
18 changes: 18 additions & 0 deletions gulpfile.js
Expand Up @@ -54,6 +54,9 @@ gulp.task('!create', ['clean'], function(done) {
executeInAppDir('react-native init ' + APP_NAME, done, true);
});
gulp.task('!postcreate', ['!create'], function() {
gulp.src(PATHS.app + '/' + APP_NAME + '/node_modules/react-native/Libraries/Renderer/ReactNativeStack*')
.pipe(transformReactNativeStack())
.pipe(gulp.dest(PATHS.app + '/' + APP_NAME + '/node_modules/react-native/Libraries/Renderer/'));
return gulp.src(PATHS.app + '/' + APP_NAME + '/android/app/src/main/AndroidManifest.xml')
.pipe(transformAndroidManifest())
.pipe(gulp.dest(PATHS.app + '/' + APP_NAME + '/android/app/src/main/'));
Expand Down Expand Up @@ -454,6 +457,21 @@ function transformAndroidManifest() {
});
}

function transformReactNativeStack() {
return through2.obj(function (file, encoding, done) {
var content = String(file.contents);
content = content.replace('module.exports = ReactNativeStackEntry;',
`ReactNativeStackEntry.ReactNativeEventEmitter = ReactNativeEventEmitter_1;
ReactNativeStackEntry.ReactNativeTagHandles = ReactNativeTagHandles_1;
ReactNativeStackEntry.ReactNativeAttributePayload = ReactNativeAttributePayload_1;
module.exports = ReactNativeStackEntry;`);
file.contents = new Buffer(content);
this.push(file);
done();
});
}

function customReporter() {
return {
error: (error) => {
Expand Down
32 changes: 16 additions & 16 deletions package.json
Expand Up @@ -24,7 +24,7 @@
},
"homepage": "https://github.com/angular/react-native-renderer/",
"devDependencies": {
"@angular/compiler-cli": "4.2.4",
"@angular/compiler-cli": "4.3.2",
"del": "^1.2.0",
"glob": "^4.0.6",
"gulp": "^3.9.0",
Expand All @@ -49,22 +49,22 @@
"typescript": "2.3.4"
},
"dependencies": {
"@angular/animations": "4.2.4",
"@angular/common": "4.2.4",
"@angular/compiler": "4.2.4",
"@angular/core": "4.2.4",
"@angular/http": "4.2.4",
"@angular/platform-browser": "4.2.4",
"@angular/platform-browser-dynamic": "4.2.4",
"@angular/platform-server": "4.2.4",
"@angular/router": "4.2.4",
"@types/jasmine": "^2.5.52",
"@types/node": "^8.0.1",
"@types/react-native": "^0.44.10",
"@angular/animations": "4.3.2",
"@angular/common": "4.3.2",
"@angular/compiler": "4.3.2",
"@angular/core": "4.3.2",
"@angular/http": "4.3.2",
"@angular/platform-browser": "4.3.2",
"@angular/platform-browser-dynamic": "4.3.2",
"@angular/platform-server": "4.3.2",
"@angular/router": "4.3.2",
"@types/jasmine": "^2.5.53",
"@types/node": "^8.0.19",
"@types/react-native": "^0.46.11",
"hammerjs": "2.0.8",
"react-native": "0.45.1",
"react-native": "0.47.1",
"reflect-metadata": "0.1.9",
"rxjs": "5.4.1",
"zone.js": "0.8.12"
"rxjs": "5.4.2",
"zone.js": "0.8.16"
}
}
8 changes: 5 additions & 3 deletions src/wrapper/wrapper_impl.ts
Expand Up @@ -9,9 +9,11 @@ var UIManager = ReactNative.NativeModules.UIManager;
var resolveAssetSource = require('react-native/Libraries/Image/resolveAssetSource');
var dismissKeyboard = require('react-native/Libraries/Utilities/dismissKeyboard');

var ReactNativeEventEmitter = require('react-native/Libraries/Renderer/src/renderers/native/ReactNativeEventEmitter');
var ReactNativeTagHandles = require('react-native/Libraries/Renderer/src/renderers/native/ReactNativeTagHandles');
var ReactNativeAttributePayload = require('react-native/Libraries/Renderer/src/renderers/native/ReactNativeAttributePayload');
var ReactNativeStackEntry = require('react-native/Libraries/Renderer/ReactNativeStack-dev');

var ReactNativeEventEmitter = ReactNativeStackEntry.ReactNativeEventEmitter;
var ReactNativeTagHandles = ReactNativeStackEntry.ReactNativeTagHandles;
var ReactNativeAttributePayload = ReactNativeStackEntry.ReactNativeAttributePayload;
var ReactNativeViewAttributes = require('react-native/Libraries/Components/View/ReactNativeViewAttributes');

overridePlatform(ReactNative.Platform.OS);
Expand Down

0 comments on commit 38773ee

Please sign in to comment.