Merge pull request #3725 from dtarnawsky/master

feat(app-rate): update sample code to use setPreferences and remove preferences property
This commit is contained in:
Damian Tarnawsky 2021-08-31 14:42:18 -07:00 committed by GitHub
commit 402b79acc8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -214,23 +214,25 @@ export interface AppUrls {
*
* ...
* // set certain preferences
* this.appRate.preferences.storeAppURL = {
* this.appRate.setPreferences({
* storeAppURL: {
* ios: '<app_id>',
* android: 'market://details?id=<package_name>',
* windows: 'ms-windows-store://review/?ProductId=<store_id>'
* }
* });
*
* this.appRate.promptForRating(true);
*
* // or, override the whole preferences object
* this.appRate.preferences = {
* this.appRate.setPreferences({
* usesUntilPrompt: 3,
* storeAppURL: {
* ios: '<app_id>',
* android: 'market://details?id=<package_name>',
* windows: 'ms-windows-store://review/?ProductId=<store_id>'
* }
* }
* });
*
* this.appRate.promptForRating(false);
* ```
@ -251,13 +253,6 @@ export interface AppUrls {
})
@Injectable()
export class AppRate extends IonicNativePlugin {
/**
* Configure various settings for the Rating View.
* See table below for options
*/
@CordovaProperty()
preferences: AppRatePreferences;
/**
* Manager custom locales
*/