# nativescript-logEntries

> A NativeScript module providing LogEntries functionalites for Android and iOS

Latest version **1.0.1** (published 2016-10-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install nativescript-logEntries
pnpm add nativescript-logEntries
yarn add nativescript-logEntries
bun add nativescript-logEntries
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2016-10-18 |
| First published | 2016-06-20 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 2 |
| Author | Antonio Cueva |
| Maintainers | antoniocuevaurraco |
| Keywords | NativeScript, LogEntries, Android, iOS |

## Links

- npm: https://www.npmjs.com/package/nativescript-logEntries
- Repository: https://github.com/AntonioCuevaUrraco/nativescript-logEntries
- Issues: https://github.com/AntonioCuevaUrraco/nativescript-logEntries/issues
- npm.io page: https://npm.io/package/nativescript-logEntries

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 1.0.1 (latest) — 2016-10-18
- 1.0.0 — 2016-06-20

## README

# nativescript-logEntries
This plugin provide a way to use LogEntries service on a NativeScript project.   
The plugin is a wrap of the android and ios official sdks   
https://github.com/logentries/le_android   
https://github.com/logentries/le_ios
## Installation
```
tns plugin add nativescript-logEntries
```
## Usage
First create a new Log for android and/or iOS and store the tokens that logEntries will provide to you   


```ts
//Somewhere on your app.

var logEntries = require("nativescript-logEntries");

 logEntries.init("YourToken");
 logEntries.log("this is the message");
```

If you want to use it to send crash reports, store the crash on devie and send it next time the device is opened.

```ts
//on app.ts

var setString = applicationSettingModule.setString;

application.on(application.uncaughtErrorEvent, function(args) {

	if (args.ios) {
        console.log("NativeScriptError: " + args.ios);
        console.log("Stacktrace: " + args.ios.stack);
        setString("crash", args.ios + args.ios.stack);
   }
	else if (args.android) {
    console.log("NativeScriptError: " + args.android);
		console.log("NativeScriptError: " + args.android.nativeException);
		console.log("NativeScriptError: " + args.android.nativeException.getMessage());
		setString("crash", args.android +
		                   args.android.nativeException +
		                   args.android.nativeException.getMessage());
	}
});
```

---
_Source: https://npm.io/package/nativescript-logEntries · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
