# hamon

> The library for publishing severity info to HAMON

Latest version **1.0.5** (published 2017-08-09) · MIT license · 0 weekly downloads

## Install

```sh
npm install hamon
pnpm add hamon
yarn add hamon
bun add hamon
```

## 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.5 |
| Published | 2017-08-09 |
| First published | 2017-08-07 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| Author | monada |
| Maintainers | monada |

## Links

- npm: https://www.npmjs.com/package/hamon
- npm.io page: https://npm.io/package/hamon

## Dependencies (1)

- [request](https://npm.io/package/request.md) ^2.81.0

## Recent versions

- 1.0.5 (latest) — 2017-08-09
- 1.0.4 — 2017-08-09
- 1.0.3 — 2017-08-09
- 1.0.2 — 2017-08-08
- 1.0.1 — 2017-08-08
- 1.0.0 — 2017-08-07

## README

# Example

```js
let util = require( 'util' );
let assert = require( 'assert' );

let hamon = ( require( './hamon' ) ).init({
//  url - is required option
    url : 'http://127.0.0.1:3030',
//  componentName - is required option
    componentName : 'test-name',
//  componentVersion - is required option
    componentVersion : '0.0.1',
//  formatMessage - is optional option
    formatMessage : ( ...messages ) => {
            return util.format( ...messages );
    }
});

let hamon2 = require( './hamon' );

assert.equal( hamon, hamon2 );

process.stdin.pipe( hamon );
hamon.pipe( process.stdout );

hamon.info({
    foo : "bar",
    bar : 42
});

assert.equal( hamon.log, hamon.info );

hamon.error( "err", "msg" );
```
#Short example

```js
let hamon = ( require( './hamon' ) ).init({
    url : 'http://127.0.0.1:3030',
    componentName : 'test-name',
    componentVersion : '0.0.1'
});

hamon.info( 'text' );

```

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