![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
react-native-umeng-rcat
Advanced tools
A Umeng lib for React Native
npm install react-native-umeng-rcat --save
在 package.json
里添加:
"rn-umeng": "git+https://github.com/RnTouna/rn-umeng.git"
然后执行命令
yarn install (或 npm install)
react-native link rn-umeng
在工程target的 Build Phases->Link Binary with Libraries
中加入
CoreTelephony.framework libz.tbd libsqlite3.tbd
在 Build Settings->Search Paths->Framework Search Paths
中加入路径 $(SRCROOT)/../node_modules/rn-umeng/ios/RCTUmeng/RCTUmeng/UMAnalytics_Sdk
在 Build Settings->Link->Other Linker Flags
中加入 -framework "UMMobClick"
$ npm install --save rn-umeng
Module Source:
$PROJECT_DIR/node_modules/rn-umeng/android
ReactInstanceManager.builder() ...
.addPackage(new UmengPackage())
@Override
protected void onResume() {
super.onResume();
MobclickAgent.onResume(this);
}
@Override
protected void onPause() {
super.onPause();
MobclickAgent.onPause(this);
}
The api mapping below
React Native Side | iOS Side | Android Side |
---|---|---|
startWithAppkey(string) | startWithAppkey(NSString) | AnalyticsConfig.setAppkey(String appkey) |
startWithAppkeyAndChannel(string,string) | N/A | UMAnalyticsConfig(Context context, String appkey, String channelId) |
setAppVersion(string) | setAppVersion(string) | Not need to set it |
setDebugMode(bool) | setLogEnabled(BOOL) | MobclickAgent.setDebugMode( true ) |
enableEncrypt(boole) | setEncryptEnabled(BOOL) | AnalyticsConfig.enableEncrypt(boolean enable) |
setCrashReportEnabled(boole) | setCrashReportEnabled(BOOL) | MobclickAgent.setCatchUncaughtExceptions(false) |
onEvent(string) | event:(NSString *)eventId | MobclickAgent.onEvent(Context context, String eventId) |
onEvent(string,{key:"value"}) | onEvent:(NSString *)eventId attributes:(NSDictionary *)attributes | MobclickAgent.onEvent(Context context, String eventId, HashMap map) |
onEvent(string,{key:"value"},0) | onEvent:(NSString *)eventId attributes:(NSDictionary *)attributes counter:(NSString *)counter | MobclickAgent.onEventValue(Context context, String id, Map<String,String> m, int du) |
onProfileSignIn('ID') | profileSignInWithPUID:(NSString *)puid | onProfileSignIn(String ID) |
onProfileSignIn('ID','Provider') | profileSignInWithPUID:(NSString *)puid provider:(NSString *)provider | onProfileSignIn(String Provider, String ID) |
onProfileSignOff() | profileSignOff | onProfileSignOff() |
onPageStart(string) | beginLogPageView:(NSString *)pageName | MobclickAgent.onPageStart(String pageName) |
onPageEnd(string) | endLogPageView:(NSString *)pageName | MobclickAgent.onPageEnd(String pageName) |
onLogPageViewInseconds('pageName',10) | logPageView:pageName seconds:seconds | N/A |
openActivityDurationTrack(boole) | N/A | MobclickAgent.openActivityDurationTrack(boolean value) |
onResume() | N/A | MobclickAgent.onResume() |
onPause() | N/A | MobclickAgent.onPause() |
getDeviceInfo((infoStr)=>{}) | getDeviceInfo | getDeviceInfo |
In your project code
import MobclickAgent from 'rn-umeng';
MobclickAgent.startWithAppkey('your appkey');
MobclickAgent.setDebugMode(true);
MobclickAgent.onEvent("testEvent");
MIT
FAQs
umeng最新的jar包
The npm package react-native-umeng-rcat receives a total of 0 weekly downloads. As such, react-native-umeng-rcat popularity was classified as not popular.
We found that react-native-umeng-rcat demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.