From aaae9fc2775090f01092781b76e86743817d51f7 Mon Sep 17 00:00:00 2001 From: Daniel Sogl Date: Sat, 21 Mar 2026 15:11:40 -0700 Subject: [PATCH] chore: clean up legacy references and unused code Update renovate.json for current dependencies. Remove Commitizen badge from README. Replace @ionic-native imports with @awesome-cordova-plugins in plugin JSDoc examples. Fill in Kommunicate documentation links. Add modern package exports to published plugin packages. Remove unused shipit script and release-please scripts. --- .eslintignore | 4 - .eslintrc | 13 --- .husky/.gitignore | 1 - .husky/pre-commit | 1 - .husky/pre-push | 1 - .prettierignore | 2 +- README.md | 2 +- gulpfile.js | 38 -------- prettier.config.js | 8 -- renovate.json | 52 ++-------- scripts/tsconfig.json | 13 --- .../plugins/app-preferences/index.ts | 4 +- .../plugins/approov-advanced-http/index.ts | 10 +- .../plugins/appsflyer/index.ts | 2 +- .../plugins/contacts/index.ts | 8 +- .../plugins/facebook/index.ts | 6 +- .../plugins/fbsdk/index.ts | 6 +- .../plugins/firebase-model/index.ts | 2 +- .../plugins/hyper-track/index.ts | 95 ++++++++++--------- .../plugins/kommunicate/index.ts | 4 +- .../plugins/newrelic/index.ts | 26 ++--- .../plugins/onesignal/index.ts | 6 +- .../plugins/photo-library/index.ts | 2 +- .../plugins/screenshot/index.ts | 2 +- .../plugins/shortcuts-android/index.ts | 2 +- .../plugins/unvired-cordova-sdk/index.ts | 4 +- .../plugins/we-cap-inbox/index.ts | 2 +- 27 files changed, 106 insertions(+), 210 deletions(-) delete mode 100644 .eslintignore delete mode 100644 .eslintrc delete mode 100644 .husky/.gitignore delete mode 100755 .husky/pre-commit delete mode 100755 .husky/pre-push delete mode 100644 gulpfile.js delete mode 100644 prettier.config.js delete mode 100644 scripts/tsconfig.json diff --git a/.eslintignore b/.eslintignore deleted file mode 100644 index c88008182..000000000 --- a/.eslintignore +++ /dev/null @@ -1,4 +0,0 @@ -scripts/ -docs/ -dist/ -node_modules/ diff --git a/.eslintrc b/.eslintrc deleted file mode 100644 index 11cf83f6a..000000000 --- a/.eslintrc +++ /dev/null @@ -1,13 +0,0 @@ -{ - "parser": "@typescript-eslint/parser", - "plugins": ["@typescript-eslint", "jsdoc"], - "extends": ["plugin:@typescript-eslint/recommended", "prettier", "plugin:jsdoc/recommended"], - "rules": { - "@typescript-eslint/no-unused-vars": ["off"], - "@typescript-eslint/no-explicit-any": ["warn"], - "@typescript-eslint/no-empty-function": ["off"], - "@typescript-eslint/ban-types": ["warn"], - "@typescript-eslint/no-empty-interface": ["warn"], - "@typescript-eslint/no-namespace": ["off"] - } -} diff --git a/.husky/.gitignore b/.husky/.gitignore deleted file mode 100644 index 31354ec13..000000000 --- a/.husky/.gitignore +++ /dev/null @@ -1 +0,0 @@ -_ diff --git a/.husky/pre-commit b/.husky/pre-commit deleted file mode 100755 index 041c660c9..000000000 --- a/.husky/pre-commit +++ /dev/null @@ -1 +0,0 @@ -npx --no-install lint-staged diff --git a/.husky/pre-push b/.husky/pre-push deleted file mode 100755 index 72c4429bc..000000000 --- a/.husky/pre-push +++ /dev/null @@ -1 +0,0 @@ -npm test diff --git a/.prettierignore b/.prettierignore index a2ecbec40..feae2daa4 100644 --- a/.prettierignore +++ b/.prettierignore @@ -4,7 +4,7 @@ node_modules .vscode dist CHANGELOG.md -.husky +lefthook.yml .prettierignore LICENSE docs/ diff --git a/README.md b/README.md index e9bdf619a..7fa7f0192 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/) ![](https://img.shields.io/npm/v/@awesome-cordova-plugins/core.svg) +![](https://img.shields.io/npm/v/@awesome-cordova-plugins/core.svg) # Awesome Cordova Plugins diff --git a/gulpfile.js b/gulpfile.js deleted file mode 100644 index 573e4a223..000000000 --- a/gulpfile.js +++ /dev/null @@ -1,38 +0,0 @@ -'use strict'; - -const gulp = require('gulp'), - minimist = require('minimist'), - rename = require('gulp-rename'), - replace = require('gulp-replace'), - _ = require('lodash'); - -const flagConfig = { - string: ['port', 'version', 'ngVersion', 'animations'], - boolean: ['dry-run'], - alias: { p: 'port', v: 'version', a: 'ngVersion' }, - default: { port: 8000 }, - }, - flags = minimist(process.argv.slice(2), flagConfig); - -/* Docs tasks */ -require('./scripts/docs/gulp-tasks')(gulp, flags); - -gulp.task('plugin:create', () => { - if (flags.n && flags.n !== '') { - const src = flags.m ? './scripts/templates/wrap-min.tmpl' : './scripts/templates/wrap.tmpl', - pluginName = flags.n, - spaced = pluginName.replace(/(?!^)([A-Z])/g, ' $1'), - kebabCase = _.kebabCase(pluginName); - - return gulp - .src(src) - .pipe(replace('{{ PluginName }}', pluginName)) - .pipe(replace('{{ Plugin_Name }}', spaced)) - .pipe(replace('{{ pluginName }}', _.lowerFirst(pluginName))) - .pipe(replace('{{ plugin-name }}', kebabCase)) - .pipe(rename('index.ts')) - .pipe(gulp.dest('./src/@awesome-cordova-plugins/plugins/' + kebabCase)); - } else { - console.log('Usage is: gulp plugin:create -n PluginName'); - } -}); diff --git a/prettier.config.js b/prettier.config.js deleted file mode 100644 index 7845f3ea4..000000000 --- a/prettier.config.js +++ /dev/null @@ -1,8 +0,0 @@ -module.exports = { - printWidth: 120, - tabWidth: 2, - useTabs: false, - semi: true, - singleQuote: true, - trailingComma: 'es5', -}; diff --git a/renovate.json b/renovate.json index 979a8dd02..d5e04c97a 100644 --- a/renovate.json +++ b/renovate.json @@ -48,31 +48,22 @@ "groupName": "linting and formatting", "automerge": true, "platformAutomerge": true, - "matchPackageNames": [ - "/^eslint/", - "/^prettier/", - "/^husky/", - "/^lint-staged/" - ] + "matchPackageNames": ["/^eslint/", "/^@eslint//", "/^prettier/", "lefthook", "typescript-eslint"] }, { "groupName": "Angular", - "allowedVersions": "<=12", + "allowedVersions": "<=20", "automerge": false, - "matchPackageNames": [ - "/^@angular//", - "/^@angular-devkit//", - "/@schematics/angular/" - ] + "matchPackageNames": ["/^@angular//", "/^@angular-devkit//", "/@schematics/angular/"] }, { "matchPackageNames": ["zone.js"], - "allowedVersions": "<=11", + "allowedVersions": "<=15", "automerge": false }, { - "matchPackageNames": ["typescript", "ts-node"], - "allowedVersions": "<=4", + "matchPackageNames": ["typescript"], + "allowedVersions": "<=5", "groupName": "TypeScript core", "automerge": false }, @@ -80,44 +71,19 @@ "groupName": "Build and bundling tools", "automerge": true, "platformAutomerge": true, - "matchPackageNames": [ - "rollup", - "webpack", - "terser-webpack-plugin", - "unminified-webpack-plugin", - "rimraf" - ] + "matchPackageNames": ["rollup", "tsx"] }, { "groupName": "Testing framework", "automerge": true, "platformAutomerge": true, - "matchPackageNames": ["jest", "ts-jest", "@types/jest"] + "matchPackageNames": ["jest", "@swc/jest", "@swc/core", "@types/jest", "jest-environment-jsdom"] }, { "groupName": "Documentation tools", "automerge": true, "platformAutomerge": true, - "matchPackageNames": [ - "dgeni", - "dgeni-packages", - "gulp", - "gulp-rename", - "gulp-replace" - ] - }, - { - "groupName": "Utility libraries", - "automerge": true, - "platformAutomerge": true, - "matchPackageNames": [ - "lodash", - "@types/lodash", - "fs-extra", - "@types/fs-extra", - "minimist", - "winston" - ] + "matchPackageNames": ["typedoc", "typedoc-plugin-markdown"] }, { "matchManagers": ["npm"], diff --git a/scripts/tsconfig.json b/scripts/tsconfig.json deleted file mode 100644 index 955fec59a..000000000 --- a/scripts/tsconfig.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "compilerOptions": { - "module": "commonjs", - "target": "es5", - "moduleResolution": "node", - "noImplicitAny": false, - "lib": ["es6"], - "paths": { - "@awesome-cordova-plugins/core": ["../src/@awesome-cordova-plugins/core"] - } - }, - "exclude": ["node_modules"] -} diff --git a/src/@awesome-cordova-plugins/plugins/app-preferences/index.ts b/src/@awesome-cordova-plugins/plugins/app-preferences/index.ts index 84e8c8cc7..63024a92e 100644 --- a/src/@awesome-cordova-plugins/plugins/app-preferences/index.ts +++ b/src/@awesome-cordova-plugins/plugins/app-preferences/index.ts @@ -140,7 +140,7 @@ export class AppPreferences extends AwesomeCordovaNativePlugin { @Cordova({ platforms: ['iOS', 'Windows', 'Windows Phone 8'], }) - cloudSync(): Object { + cloudSync(): object { return; } @@ -153,7 +153,7 @@ export class AppPreferences extends AwesomeCordovaNativePlugin { @Cordova({ platforms: ['iOS', 'Windows', 'Windows Phone 8'], }) - defaults(): Object { + defaults(): object { return; } } diff --git a/src/@awesome-cordova-plugins/plugins/approov-advanced-http/index.ts b/src/@awesome-cordova-plugins/plugins/approov-advanced-http/index.ts index 6e87dfa2f..f09039f61 100644 --- a/src/@awesome-cordova-plugins/plugins/approov-advanced-http/index.ts +++ b/src/@awesome-cordova-plugins/plugins/approov-advanced-http/index.ts @@ -725,7 +725,7 @@ export class HTTP extends AwesomeCordovaNativePlugin { } @Cordova({ sync: false }) - approovGetDeviceID(): Promise { + approovGetDeviceID(): Promise { return; } @@ -735,22 +735,22 @@ export class HTTP extends AwesomeCordovaNativePlugin { } @Cordova({ sync: false }) - approovFetchToken(url: string): Promise { + approovFetchToken(url: string): Promise { return; } @Cordova({ sync: false }) - approovGetMessageSignature(message: string): Promise { + approovGetMessageSignature(message: string): Promise { return; } @Cordova({ sync: false }) - approovFetchSecureString(key: string, newDef: string): Promise { + approovFetchSecureString(key: string, newDef: string): Promise { return; } @Cordova({ sync: false }) - approovFetchCustomJWT(payload: string): Promise { + approovFetchCustomJWT(payload: string): Promise { return; } } diff --git a/src/@awesome-cordova-plugins/plugins/appsflyer/index.ts b/src/@awesome-cordova-plugins/plugins/appsflyer/index.ts index be0c3a4ea..98578e64c 100644 --- a/src/@awesome-cordova-plugins/plugins/appsflyer/index.ts +++ b/src/@awesome-cordova-plugins/plugins/appsflyer/index.ts @@ -208,5 +208,5 @@ export class Appsflyer extends AwesomeCordovaNativePlugin { * @param {Object} options Additional Parameters to track */ @Cordova({ sync: true }) - logCrossPromotionAndOpenStore(appId: string, campaign: string, options: Object): void {} + logCrossPromotionAndOpenStore(appId: string, campaign: string, options: object): void {} } diff --git a/src/@awesome-cordova-plugins/plugins/contacts/index.ts b/src/@awesome-cordova-plugins/plugins/contacts/index.ts index 7dcc2802a..63adec3a0 100644 --- a/src/@awesome-cordova-plugins/plugins/contacts/index.ts +++ b/src/@awesome-cordova-plugins/plugins/contacts/index.ts @@ -208,7 +208,11 @@ export interface IContactField { * @hidden */ export class ContactField implements IContactField { - constructor(public type?: string, public value?: string, public pref?: boolean) {} + constructor( + public type?: string, + public value?: string, + public pref?: boolean + ) {} } export interface IContactAddress { @@ -307,7 +311,7 @@ export class ContactFindOptions implements IContactFindOptions { * @usage * * ```typescript - * import { Contacts, Contact, ContactField, ContactName } from '@ionic-native/contacts/ngx'; + * import { Contacts, Contact, ContactField, ContactName } from '@awesome-cordova-plugins/contacts/ngx'; * * constructor(private contacts: Contacts) { } * diff --git a/src/@awesome-cordova-plugins/plugins/facebook/index.ts b/src/@awesome-cordova-plugins/plugins/facebook/index.ts index c744ce5d0..22f0f4f02 100644 --- a/src/@awesome-cordova-plugins/plugins/facebook/index.ts +++ b/src/@awesome-cordova-plugins/plugins/facebook/index.ts @@ -396,7 +396,7 @@ export class Facebook extends AwesomeCordovaNativePlugin { * @param {Object} userData An object containing data about the user */ @Cordova() - setUserData(userData: Object): Promise { + setUserData(userData: object): Promise { return; } @@ -420,7 +420,7 @@ export class Facebook extends AwesomeCordovaNativePlugin { successIndex: 3, errorIndex: 4, }) - logEvent(name: string, params?: Object, valueToSum?: number): Promise { + logEvent(name: string, params?: object, valueToSum?: number): Promise { return; } @@ -466,7 +466,7 @@ export class Facebook extends AwesomeCordovaNativePlugin { * @returns {Promise} */ @Cordova() - logPurchase(value: number, currency: string, params?: Object): Promise { + logPurchase(value: number, currency: string, params?: object): Promise { return; } diff --git a/src/@awesome-cordova-plugins/plugins/fbsdk/index.ts b/src/@awesome-cordova-plugins/plugins/fbsdk/index.ts index 53888f0d5..79cae2e36 100644 --- a/src/@awesome-cordova-plugins/plugins/fbsdk/index.ts +++ b/src/@awesome-cordova-plugins/plugins/fbsdk/index.ts @@ -401,7 +401,7 @@ export class FbSdk extends AwesomeCordovaNativePlugin { * @param {Object} userData An object containing data about the user */ @Cordova() - setUserData(userData: Object): Promise { + setUserData(userData: object): Promise { return; } @@ -425,7 +425,7 @@ export class FbSdk extends AwesomeCordovaNativePlugin { successIndex: 3, errorIndex: 4, }) - logEvent(name: string, params?: Object, valueToSum?: number): Promise { + logEvent(name: string, params?: object, valueToSum?: number): Promise { return; } @@ -471,7 +471,7 @@ export class FbSdk extends AwesomeCordovaNativePlugin { * @returns {Promise} */ @Cordova() - logPurchase(value: number, currency: string, params?: Object): Promise { + logPurchase(value: number, currency: string, params?: object): Promise { return; } diff --git a/src/@awesome-cordova-plugins/plugins/firebase-model/index.ts b/src/@awesome-cordova-plugins/plugins/firebase-model/index.ts index f2d238590..9ee59eac7 100644 --- a/src/@awesome-cordova-plugins/plugins/firebase-model/index.ts +++ b/src/@awesome-cordova-plugins/plugins/firebase-model/index.ts @@ -51,7 +51,7 @@ export class FirebaseModelInput { * @description This plugin downloads the TensorFlow model from firebase and classify the images. * * ```typescript - * import { FirebaseModel } from '@ionic-native/ionic-native-firebase-model'; + * import { FirebaseModel } from '@awesome-cordova-plugins/firebase-model'; * * * constructor(private firebaseModel: FirebaseModel) { } diff --git a/src/@awesome-cordova-plugins/plugins/hyper-track/index.ts b/src/@awesome-cordova-plugins/plugins/hyper-track/index.ts index 398c4384e..188394ebc 100644 --- a/src/@awesome-cordova-plugins/plugins/hyper-track/index.ts +++ b/src/@awesome-cordova-plugins/plugins/hyper-track/index.ts @@ -1,7 +1,7 @@ import { Injectable } from '@angular/core'; import { AwesomeCordovaNativePlugin, Cordova, Plugin } from '@awesome-cordova-plugins/core'; -const hypertrackIonicPluginVersion = "0.2.0" +const hypertrackIonicPluginVersion = '0.2.0'; // Minimal cordova-plugin-hypertrack-v3 version: 0.5.0 @Plugin({ pluginName: 'cordova-plugin-hypertrack-v3', @@ -42,7 +42,7 @@ interface SuccessHandler { (): any; } interface LocationReceiver { - (location: CordovaLatestLocationResult): any; + (location: CordovaLatestLocationResult): any; } // SDK instance that exposed from Cordova utilizes usage of callbacks, so we @@ -51,7 +51,7 @@ interface HyperTrackCordova { getDeviceId(success: DeviceIdReceiver, error: FailureHandler): void; isRunning(success: TrackingStateReceiver, error: FailureHandler): void; setDeviceName(name: string, success: SuccessHandler, error: FailureHandler): void; - setDeviceMetadata(metadata: Object, success: SuccessHandler, error: FailureHandler): void; + setDeviceMetadata(metadata: object, success: SuccessHandler, error: FailureHandler): void; setTrackingNotificationProperties( title: string, message: string, @@ -59,7 +59,7 @@ interface HyperTrackCordova { error: FailureHandler ): void; addGeoTag( - geotagData: Object, + geotagData: object, expectedLocation: Coordinates | undefined, success: SuccessHandler, error: FailureHandler @@ -77,7 +77,10 @@ export class CoordinatesValidationError extends Error {} /** Wrapper class for passing spatial geoposition as a geotag's expected location */ export class Coordinates { - constructor(public latitude: number, public longitude: number) { + constructor( + public latitude: number, + public longitude: number + ) { if (latitude < -90.0 || latitude > 90.0 || longitude < -180.0 || longitude > 180.0) { throw new CoordinatesValidationError('latitude and longitude should be of correct values'); } @@ -85,7 +88,7 @@ export class Coordinates { public toString = (): string => { return JSON.stringify(this); - } + }; } /** A blocker is an obstacle that needs to be resolved to achieve reliable tracking. */ @@ -100,28 +103,32 @@ export interface Blocker { resolve: () => void; } -export type CordovaLatestLocationResult = { - type: "location", - location: Coordinates, -} | { - type: "outage", - outage: { - code: number, - name: keyof typeof Outage - } -} +export type CordovaLatestLocationResult = + | { + type: 'location'; + location: Coordinates; + } + | { + type: 'outage'; + outage: { + code: number; + name: keyof typeof Outage; + }; + }; -export type LocationResult = { - type: LocationResultType.LOCATION, - value: Coordinates -} | -{ - type: LocationResultType.OUTAGE, - value: Outage -} +export type LocationResult = + | { + type: LocationResultType.LOCATION; + value: Coordinates; + } + | { + type: LocationResultType.OUTAGE; + value: Outage; + }; export enum LocationResultType { - LOCATION, OUTAGE + LOCATION, + OUTAGE, } export enum Outage { @@ -131,7 +138,7 @@ export enum Outage { NOT_TRACKING, START_HAS_NOT_FINISHED, NO_GPS_SIGNAL, - RESTART_REQUIRED + RESTART_REQUIRED, } /** @@ -175,7 +182,7 @@ export class HyperTrack { * @see {@link https://dashboard.hypertrack.com/setup}. */ static initialize(publishableKey: string): Promise { - console.log(`Hypertrack Ionic plugin version ${hypertrackIonicPluginVersion}`) + console.log(`Hypertrack Ionic plugin version ${hypertrackIonicPluginVersion}`); return new Promise((resolve, reject) => { new HyperTrackPlugin() .initialize(publishableKey) @@ -235,7 +242,7 @@ export class HyperTrack { * * @param metadata key-value pais of properties. */ - setDeviceMetadata(metadata: Object): Promise { + setDeviceMetadata(metadata: object): Promise { return new Promise((resolve, reject) => { this.cordovaInstanceHandle.setDeviceMetadata( metadata, @@ -268,7 +275,7 @@ export class HyperTrack { * @param geotagData * @param expectedLocation */ - addGeotag(geotagData: Object, expectedLocation?: Coordinates): Promise { + addGeotag(geotagData: object, expectedLocation?: Coordinates): Promise { return new Promise((resolve, reject) => { this.cordovaInstanceHandle.addGeoTag( geotagData, @@ -332,46 +339,46 @@ export class HyperTrack { }); } - /** - * Resolves latest device location that was sent by the SDK. + /** + * Resolves latest device location that was sent by the SDK. * Only available for Android platform. * */ getLatestLocation(): Promise { return new Promise((resolve, reject) => { this.cordovaInstanceHandle.getLatestLocation( - locationResult => resolve(this.handleLocationResult(locationResult)), - err => reject(err) + (locationResult) => resolve(this.handleLocationResult(locationResult)), + (err) => reject(err) ); }); } - /** - * Resolves latest device location from system location provider. + /** + * Resolves latest device location from system location provider. * Only available for Android platform. * */ getCurrentLocation(): Promise { return new Promise((resolve, reject) => { this.cordovaInstanceHandle.getCurrentLocation( - locationResult => resolve(this.handleLocationResult(locationResult)), - err => reject(err) + (locationResult) => resolve(this.handleLocationResult(locationResult)), + (err) => reject(err) ); }); } private handleLocationResult(locationResult: CordovaLatestLocationResult): LocationResult { switch (locationResult.type) { - case "location": { + case 'location': { return { type: LocationResultType.LOCATION, - value: locationResult.location - } + value: locationResult.location, + }; } - case "outage": { - const outage = Outage[locationResult.outage.name] + case 'outage': { + const outage = Outage[locationResult.outage.name]; return { type: LocationResultType.OUTAGE, - value: outage - } + value: outage, + }; } } } diff --git a/src/@awesome-cordova-plugins/plugins/kommunicate/index.ts b/src/@awesome-cordova-plugins/plugins/kommunicate/index.ts index 3adfc4916..b4f236538 100644 --- a/src/@awesome-cordova-plugins/plugins/kommunicate/index.ts +++ b/src/@awesome-cordova-plugins/plugins/kommunicate/index.ts @@ -7,8 +7,8 @@ import { Observable } from 'rxjs'; * @description * The plugin for the Kommunicate SDK. * With the help of this plugin, you can easily add human + bot chat support functionality to you app. - * Refer to: TODO: insert site link - * For documentation: TODO: insert link + * Refer to: https://www.kommunicate.io/ + * For documentation: https://docs.kommunicate.io/ * @usage * ```typescript * import { Kommunicate } from '@awesome-cordova-plugins/Kommunicate'; diff --git a/src/@awesome-cordova-plugins/plugins/newrelic/index.ts b/src/@awesome-cordova-plugins/plugins/newrelic/index.ts index 667d3c6db..bdfea20bf 100644 --- a/src/@awesome-cordova-plugins/plugins/newrelic/index.ts +++ b/src/@awesome-cordova-plugins/plugins/newrelic/index.ts @@ -174,7 +174,7 @@ export class NewRelic extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - recordMetric(name: string, category: any, value: Number, countUnit: string, valueUnit: string): void { + recordMetric(name: string, category: any, value: number, countUnit: string, valueUnit: string): void { return; // We add return; here to avoid any IDE / Compiler errors } @@ -197,7 +197,7 @@ export class NewRelic extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - setMaxEventPoolSize(maxPoolSize: Number): void { + setMaxEventPoolSize(maxPoolSize: number): void { return; // We add return; here to avoid any IDE / Compiler errors } @@ -211,7 +211,7 @@ export class NewRelic extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - setMaxEventBufferTime(maxBufferTimeInSeconds: Number): void { + setMaxEventBufferTime(maxBufferTimeInSeconds: number): void { return; // We add return; here to avoid any IDE / Compiler errors } @@ -223,7 +223,7 @@ export class NewRelic extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - analyticsEventEnabled(enabled: Boolean): void { + analyticsEventEnabled(enabled: boolean): void { return; // We add return; here to avoid any IDE / Compiler errors } @@ -234,7 +234,7 @@ export class NewRelic extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - networkRequestEnabled(enabled: Boolean): void { + networkRequestEnabled(enabled: boolean): void { return; // We add return; here to avoid any IDE / Compiler errors } @@ -245,7 +245,7 @@ export class NewRelic extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - networkErrorRequestEnabled(enabled: Boolean): void { + networkErrorRequestEnabled(enabled: boolean): void { return; // We add return; here to avoid any IDE / Compiler errors } @@ -256,7 +256,7 @@ export class NewRelic extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - httpRequestBodyCaptureEnabled(enabled: Boolean): void { + httpRequestBodyCaptureEnabled(enabled: boolean): void { return; // We add return; here to avoid any IDE / Compiler errors } @@ -277,11 +277,11 @@ export class NewRelic extends AwesomeCordovaNativePlugin { noticeHttpTransaction( url: string, method: string, - status: Number, - startTime: Number, - endTime: Number, - bytesSent: Number, - bytesReceived: Number, + status: number, + startTime: number, + endTime: number, + bytesSent: number, + bytesReceived: number, body: string ): void { return; // We add return; here to avoid any IDE / Compiler errors @@ -300,7 +300,7 @@ export class NewRelic extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - noticeNetworkFailure(url: string, method: string, startTime: Number, endTime: Number, failure: string): void { + noticeNetworkFailure(url: string, method: string, startTime: number, endTime: number, failure: string): void { return; // We add return; here to avoid any IDE / Compiler errors } diff --git a/src/@awesome-cordova-plugins/plugins/onesignal/index.ts b/src/@awesome-cordova-plugins/plugins/onesignal/index.ts index 51ab3eee0..037318c1c 100644 --- a/src/@awesome-cordova-plugins/plugins/onesignal/index.ts +++ b/src/@awesome-cordova-plugins/plugins/onesignal/index.ts @@ -851,7 +851,7 @@ export class OneSignal extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - addTrigger(key: string, value: string | number | Object): void {} + addTrigger(key: string, value: string | number | object): void {} /** * Add a map of triggers. May show an In-App Message if its trigger conditions were met. @@ -861,7 +861,7 @@ export class OneSignal extends AwesomeCordovaNativePlugin { @Cordova({ sync: true, }) - addTriggers(triggers: Object): void {} + addTriggers(triggers: object): void {} /** * Removes a single trigger for the given key. May show an In-App Message if its trigger conditions were met. @@ -890,7 +890,7 @@ export class OneSignal extends AwesomeCordovaNativePlugin { * @returns {Promise} Return value set with `addTrigger`, or `null`/`nil` (iOS) if never set or removed. */ @Cordova() - getTriggerValueForKey(key: string): Promise { + getTriggerValueForKey(key: string): Promise { return; } diff --git a/src/@awesome-cordova-plugins/plugins/photo-library/index.ts b/src/@awesome-cordova-plugins/plugins/photo-library/index.ts index 8d51f3a56..293356d21 100644 --- a/src/@awesome-cordova-plugins/plugins/photo-library/index.ts +++ b/src/@awesome-cordova-plugins/plugins/photo-library/index.ts @@ -24,7 +24,7 @@ export interface CordovaFiniteObservableOptions extends CordovaOptions { */ export function CordovaFiniteObservable(opts: CordovaFiniteObservableOptions = {}) { opts.observable = true; - return (target: Object, methodName: string, descriptor: TypedPropertyDescriptor) => { + return (target: object, methodName: string, descriptor: TypedPropertyDescriptor) => { return { value(...args: any[]) { const wrappedObservable: Observable = wrap(this, methodName, opts).apply(this, args); diff --git a/src/@awesome-cordova-plugins/plugins/screenshot/index.ts b/src/@awesome-cordova-plugins/plugins/screenshot/index.ts index d17045e11..93ee8cbe2 100644 --- a/src/@awesome-cordova-plugins/plugins/screenshot/index.ts +++ b/src/@awesome-cordova-plugins/plugins/screenshot/index.ts @@ -8,7 +8,7 @@ declare const navigator: any; * @description Captures a screen shot * @usage * ```typescript - * import { Screenshot } from '@ionic-native/screenshot/ngx'; + * import { Screenshot } from '@awesome-cordova-plugins/screenshot/ngx'; * * constructor(private screenshot: Screenshot) { } * diff --git a/src/@awesome-cordova-plugins/plugins/shortcuts-android/index.ts b/src/@awesome-cordova-plugins/plugins/shortcuts-android/index.ts index a8094b866..cb095e2fa 100644 --- a/src/@awesome-cordova-plugins/plugins/shortcuts-android/index.ts +++ b/src/@awesome-cordova-plugins/plugins/shortcuts-android/index.ts @@ -44,7 +44,7 @@ export interface Shortcut { * Please do refer to the original plugin's repo for detailed usage. The usage example here might not be sufficient. * * ```typescript - * import { ShortcutsAndroid } from '@ionic-native/shortcuts-android/ngx'; + * import { ShortcutsAndroid } from '@awesome-cordova-plugins/shortcuts-android/ngx'; * * * constructor(private shortcutsAndroid: ShortcutsAndroid) { } diff --git a/src/@awesome-cordova-plugins/plugins/unvired-cordova-sdk/index.ts b/src/@awesome-cordova-plugins/plugins/unvired-cordova-sdk/index.ts index f72643e15..431f46011 100644 --- a/src/@awesome-cordova-plugins/plugins/unvired-cordova-sdk/index.ts +++ b/src/@awesome-cordova-plugins/plugins/unvired-cordova-sdk/index.ts @@ -118,9 +118,7 @@ export enum LoginType { * SAML 2.0 Login Type */ saml2 = 'SAML2', - /** - * TODO: - */ + /** Custom authentication */ custom = 'CUSTOM', } diff --git a/src/@awesome-cordova-plugins/plugins/we-cap-inbox/index.ts b/src/@awesome-cordova-plugins/plugins/we-cap-inbox/index.ts index fdb1ddeed..793599c83 100644 --- a/src/@awesome-cordova-plugins/plugins/we-cap-inbox/index.ts +++ b/src/@awesome-cordova-plugins/plugins/we-cap-inbox/index.ts @@ -45,7 +45,7 @@ export class WECapInbox extends AwesomeCordovaNativePlugin { * @returns {Promise} - The count of notifications. */ @Cordova() - getNotificationCount(successCallback: (count: String) => void, errorCallback: (error: string) => void): Promise { + getNotificationCount(successCallback: (count: string) => void, errorCallback: (error: string) => void): Promise { return; }