Skip to content

Commit bd632ca

Browse files
committed
update Example to React Native 0.47
1 parent 2ab0c44 commit bd632ca

File tree

8 files changed

+6492
-254
lines changed

8 files changed

+6492
-254
lines changed

Example/.flowconfig

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ emoji=true
2626

2727
module.system=haste
2828

29-
experimental.strict_type_args=true
30-
3129
munge_underscores=true
3230

3331
module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> 'RelativeImageStub'
@@ -36,12 +34,12 @@ suppress_type=$FlowIssue
3634
suppress_type=$FlowFixMe
3735
suppress_type=$FixMe
3836

39-
suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(4[0-5]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
40-
suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(4[0-5]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
37+
suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(4[0-9]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
38+
suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(4[0-9]\\|[1-3][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
4139
suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
4240
suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError
4341

4442
unsafe.enable_getters_and_setters=true
4543

4644
[version]
47-
^0.45.0
45+
^0.49.1

Example/android/app/build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ def enableProguardInReleaseBuilds = false
9191

9292
android {
9393
compileSdkVersion 25
94-
buildToolsVersion "25.0.3"
94+
buildToolsVersion '25.0.3'
9595

9696
defaultConfig {
9797
applicationId "com.example"

Example/android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#Fri Jun 16 11:11:40 CST 2017
1+
#Sat Aug 05 21:31:48 CST 2017
22
distributionBase=GRADLE_USER_HOME
33
distributionPath=wrapper/dists
44
zipStoreBase=GRADLE_USER_HOME

Example/index.android.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
import React, { Component } from "react";
88
import { AppRegistry, StyleSheet, View, TextInput, ToastAndroid, DeviceEventEmitter } from "react-native";
9-
import { Recognizer, Synthesizer } from "react-native-speech-iflytek";
9+
import { Recognizer, Synthesizer, SpeechConstant } from "react-native-speech-iflytek";
1010
import Button from "react-native-button";
1111

1212
export default class Example extends Component {
@@ -63,6 +63,7 @@ export default class Example extends Component {
6363
onRecordStart() {
6464
ToastAndroid.show("Begin to record", ToastAndroid.SHORT);
6565
this.setState({ recordBtnText: "Release to stop" });
66+
Synthesizer.setParameter(SpeechConstant.VOICE_NAME, "xiaoyu");
6667
Recognizer.start();
6768
}
6869

Example/ios/Example.xcodeproj/project.pbxproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -874,7 +874,7 @@
874874
);
875875
runOnlyForDeploymentPostprocessing = 0;
876876
shellPath = /bin/sh;
877-
shellScript = "export NODE_BINARY=node\n../node_modules/react-native/packager/react-native-xcode.sh";
877+
shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh";
878878
};
879879
2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */ = {
880880
isa = PBXShellScriptBuildPhase;
@@ -888,7 +888,7 @@
888888
);
889889
runOnlyForDeploymentPostprocessing = 0;
890890
shellPath = /bin/sh;
891-
shellScript = "export NODE_BINARY=node\n../node_modules/react-native/packager/react-native-xcode.sh";
891+
shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh";
892892
};
893893
/* End PBXShellScriptBuildPhase section */
894894

0 commit comments

Comments
 (0)