0.1.8 • Published 4 months ago

expo-aliyun-push v0.1.8

Weekly downloads
-
License
MIT
Repository
github
Last release
4 months ago

安装

  1. npx expo install aliyun-react-native-push
  2. npx expo install expo-aliyun-push

配置

app.json

"plugins": [
  [
    "expo-aliyun-push",
    {
      "appKey": "xxx",
      "appSecret": "xxx"
    }
  ]
]

使用

import * as AliyunPush from 'aliyun-react-native-push';

 AliyunPush.initPush('appKey', 'appSecret').then(initPushRes => {
  const code = initPushRes.code;
  if (code === AliyunPush.kAliyunPushSuccessCode) {
    Alert.alert('Init iOS AliyunPush successfully👋');
  } else {
    const errorMsg = initPushRes.errorMsg?.toString();
    Alert.alert(`Failed to Init iOS AliyunPush, errorMsg: ${errorMsg}`);
  }
  });

TODO

x 支持 android

开发

编译 config plugin

yarn build plugin

发布

npm publish

0.1.8

4 months ago

0.1.6

4 months ago

0.1.5

4 months ago

0.1.4

4 months ago

0.1.3

4 months ago

0.1.2

5 months ago

0.1.1

5 months ago

0.1.0

9 months ago