From cce897daa0f3f16614075e3a9f275b0c7610938c Mon Sep 17 00:00:00 2001 From: Hevin Date: Fri, 15 Dec 2017 14:50:38 +0800 Subject: [PATCH] Update install step of ionic --- README.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/README.md b/README.md index 63cc890..19317cb 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,28 @@ cordova plugin add Your_Plugin_Path --variable APP_KEY=your_jpush_appkey ``` +### Ionic + +如果使用了 Ionic,可以再安装 @jiguang-ionic/jpush 包,适配 ionic-native: + +```shell +npm install @jiguang-ionic/jpush --save +``` + +然后在 *app.module.ts* 中增加 + +```js +import { JPush } from '@jiguang-ionic/jpush'; +... + providers: [ + ... + JPush, + ... + ] +``` + +具体可参考 ./ionic/example 中的文件。 + > 在使用 Xcode 8 调试 iOS 项目时,需要先在项目配置界面的 Capabilities 中打开 Push Notifications 开关。 ## Usage