# cordova-plugin-net-diagno

> Cordova Net Diagno Plugin

Latest version **0.1.1** (published 2018-08-14) · MIT license · 0 weekly downloads

## Install

```sh
npm install cordova-plugin-net-diagno
pnpm add cordova-plugin-net-diagno
yarn add cordova-plugin-net-diagno
bun add cordova-plugin-net-diagno
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.1 |
| Published | 2018-08-14 |
| First published | 2018-08-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 304.3 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | jsckdao |
| Maintainers | jsckdao |
| Keywords | cordova, diagno, ecosystem:cordova, cordova-android, cordova-ios |

## Links

- npm: https://www.npmjs.com/package/cordova-plugin-net-diagno
- Repository: https://github.com/jsckdao/cordova-plugin-net-diagno
- Homepage: https://github.com/jsckdao/cordova-plugin-net-diagno#readme
- Issues: https://github.com/jsckdao/cordova-plugin-net-diagno/issues
- npm.io page: https://npm.io/package/cordova-plugin-net-diagno

## 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

- 0.1.1 (latest) — 2018-08-14

## README

# cordova-plugin-net-diagno

这是一个用于网络诊断的 cordova 插件. 利用ping和traceroute的原理, 
对指定域名（通常为后台API的提供域名）进行网络诊断, 并收集诊断日志. 
该插件集成了由网易提供的网络诊断开源代码, 
支持([IOS](https://github.com/Lede-Inc/LDNetDiagnoService_IOS) 
与 [android](https://github.com/Lede-Inc/LDNetDiagnoService_Android))

## Usage

```js
window.netdiagno({ 
    // 指定的域名
    dormain: 'www.baidu.com', 
    // 开始
    onStart: () => {
        console.log('网络诊断开始......\n');
    },
    // 接收实时输出的日志数据
    onProgress: (output) => {
        console.log(output)
    },
    // 完成
    onFinished: (allOutput) => {
        console.log('网络诊断结束');
    },
    onError: (err) => {
        console('错误:' + err.toString());
    }
});
```

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