mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-01-19 08:32:52 +08:00
docs(newrelic): update docs (#4420)
* Adding Newrelic support for Awesome plugins * Adding more static methods for newrelic cordova plugin * adding documentation for newrelic plugin * Updating newrelic cordova plugin repo * Update index.ts * fix:updating correct cordova plugin repo * docs: added Documentation for NewRelic Plugin * ADDED Record Error and Updated set Attribute Method Co-authored-by: Daniel Sogl <daniel@sogls.de>
This commit is contained in:
parent
0579e67e96
commit
82f7fd9e0a
20
docs/plugins/newrelic/README.md
Normal file
20
docs/plugins/newrelic/README.md
Normal file
@ -0,0 +1,20 @@
|
||||
# newrelic mobile
|
||||
|
||||
```
|
||||
$ ionic cordova plugin add https://github.com/newrelic/newrelic-cordova-plugin.git --variable IOS_APP_TOKEN="{ios-app-token}" --variable ANDROID_APP_TOKEN="{android-app-token}"
|
||||
$ npm install @awesome-cordova-plugins/newrelic
|
||||
```
|
||||
|
||||
## [Usage Documentation](https://danielsogl.gitbook.io/awesome-cordova-plugins/plugins/newrelic/)
|
||||
|
||||
Plugin Repo: [https://github.com/newrelic/newrelic-cordova-plugin](https://github.com/newrelic/newrelic-cordova-plugin)
|
||||
|
||||
This NewRelic plugin collect crashes, network traffic, and other information for hybrid apps using native components.
|
||||
|
||||
## Supported platforms
|
||||
|
||||
- Android
|
||||
- iOS
|
||||
|
||||
|
||||
|
@ -29,7 +29,7 @@ import { Observable } from 'rxjs';
|
||||
pluginRef: 'NewRelic', // the variable reference to call the plugin, example: navigator.geolocation
|
||||
repo: 'https://github.com/newrelic/newrelic-cordova-plugin', // the github repository URL for the plugin
|
||||
install:
|
||||
'ionic cordova plugin add https://github.com/ndesai-newrelic/newrelic-cordova-plugin.git --variable IOS_APP_TOKEN="{ios-app-token}" --variable ANDROID_APP_TOKEN="{android-app-token}"', // OPTIONAL install command, in case the plugin requires variables
|
||||
'ionic cordova plugin add https://github.com/newrelic/newrelic-cordova-plugin.git --variable IOS_APP_TOKEN="{ios-app-token}" --variable ANDROID_APP_TOKEN="{android-app-token}"', // OPTIONAL install command, in case the plugin requires variables
|
||||
installVariables: ['IOS_APP_TOKEN', 'ANDROID_APP_TOKEN'], // OPTIONAL the plugin requires variables
|
||||
platforms: ['Android', 'iOS'], // Array of platforms supported, example: ['Android', 'iOS']
|
||||
})
|
||||
@ -56,7 +56,7 @@ export class NewRelic extends AwesomeCordovaNativePlugin {
|
||||
@Cordova({
|
||||
sync: true,
|
||||
})
|
||||
setAttribute(name: string, value: string): void {
|
||||
setAttribute(name: string, value: any): void {
|
||||
return; // We add return; here to avoid any IDE / Compiler errors
|
||||
}
|
||||
|
||||
@ -124,19 +124,6 @@ export class NewRelic extends AwesomeCordovaNativePlugin {
|
||||
return; // We add return; here to avoid any IDE / Compiler errors
|
||||
}
|
||||
|
||||
/**
|
||||
* Records JavaScript errors for ionic.
|
||||
* @param {string} name The name of the error.
|
||||
* @param {string} message The message of the error.
|
||||
* @param {string} stack The error stack of the error.
|
||||
* @param {boolean} isFatal The flag for whether the error is fatal.
|
||||
*/
|
||||
@Cordova({
|
||||
sync: true,
|
||||
})
|
||||
recordError(name: string, message: string, stack: string, isFatal: boolean): void {
|
||||
return; // We add return; here to avoid any IDE / Compiler errors
|
||||
}
|
||||
|
||||
/**
|
||||
* Throws a demo run-time exception to test New Relic crash reporting.
|
||||
@ -317,4 +304,16 @@ export class NewRelic extends AwesomeCordovaNativePlugin {
|
||||
noticeNetworkFailure(url: string, method: string, startTime: Number, endTime: Number, failure: string): void {
|
||||
return; // We add return; here to avoid any IDE / Compiler errors
|
||||
}
|
||||
|
||||
/**
|
||||
* Records JavaScript errors for ionic.
|
||||
* @param {Error} err The error to report.
|
||||
*/
|
||||
@Cordova({
|
||||
sync: true,
|
||||
})
|
||||
recordError(err: Error): void {
|
||||
return; // We add return; here to avoid any IDE / Compiler errors
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user