From 62cb399a3f5912bf0d1a760348cc7915b271baad Mon Sep 17 00:00:00 2001 From: cyqresig Date: Sun, 26 Mar 2017 22:54:12 +0800 Subject: [PATCH] added support for ios using react-native0.40+ --- README.md | 5 +++++ ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.h | 2 +- ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.m | 6 +++--- package.json | 2 +- 4 files changed, 10 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 039c1e1..8b6b1d5 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,11 @@ Mac下Android Studio中获取SHA1和MD5请点击[这里][3] npm install react-native-smart-amap-location --save ``` +## Notice + +这个版本仅支持react-native 0.40及以上, 如果你想使用旧的版本,使用`npm install react-native-smart-amap-location@untilRN0.40 --save` + + ## 安装 (iOS) * 将RCTAMapLocation.xcodeproj作为Library拖进你的Xcode里的project中. diff --git a/ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.h b/ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.h index 9207d0b..436c724 100644 --- a/ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.h +++ b/ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.h @@ -1,4 +1,4 @@ -#import "RCTBridgeModule.h" +#import @interface RCTAMapLocation : NSObject diff --git a/ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.m b/ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.m index 00bb6f2..8c9ee91 100644 --- a/ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.m +++ b/ios/RCTAMapLocation/RCTAMapLocation/RCTAMapLocation.m @@ -3,9 +3,9 @@ #define DefaultReGeocodeTimeout 5 #import "RCTAMapLocation.h" -#import "RCTUtils.h" -#import "RCTBridge.h" -#import "RCTEventDispatcher.h" +#import +#import +#import #import #import diff --git a/package.json b/package.json index 855dce1..f02ecf3 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-native-smart-amap-location", - "version": "1.1.1", + "version": "1.1.3", "description": "A AMap location Library for React Native apps.", "main": "AMapLocation.js", "scripts": {