【问题标题】:Ionic native app rate not working离子原生应用程序速率不起作用
【发布时间】:2018-05-18 18:24:21
【问题描述】:

我尝试在 ionic 的 android 平台上显示应用评分屏幕。无法使用 Ionic Native 插件。

import { ViewController, Platform } from 'ionic-angular';
import { AppRate } from '@ionic-native/app-rate';        

export class Popover {

    constructor(
        private appRate: AppRate,
        public platform: Platform) { }

        rate() {
            this.platform.ready().then(() => {
            this.appRate.preferences = {
                usesUntilPrompt: 2,
                storeAppURL: {
                    ios: 'id12233',
                    android: 'market://details?id=<com.sample.activity>',
                }
            };
            this.appRate.promptForRating(true);
        });
    }    
}

【问题讨论】:

  • 你在哪里打电话给rate()
  • 我使用 ngClick 调用了根页面屏幕中的弹出菜单
  • 您是在设备还是浏览器中尝试?始终检查设备中的插件
  • 总是在设备中尝试但无法正常工作

标签: angular typescript ionic3 ionic-native


【解决方案1】:

检查您的安装应用率插件并尝试以下链接 enter link description here

$ ionic cordova plugin add cordova-plugin-apprate
$ npm install --save @ionic-native/app-rate

【讨论】:

    猜你喜欢
    • 2019-02-08
    • 2017-02-15
    • 1970-01-01
    • 2019-03-16
    • 2017-11-22
    • 2016-04-23
    • 1970-01-01
    • 2016-07-23
    • 2019-05-26
    相关资源
    最近更新 更多