# random-hexhash

> Return a random hex hash.

Latest version **1.0.0** (published 2016-04-26) · MIT license · 0 weekly downloads

## Install

```sh
npm install random-hexhash
pnpm add random-hexhash
yarn add random-hexhash
bun add random-hexhash
```

## 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.0 |
| Published | 2016-04-26 |
| First published | 2016-04-25 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | bubkoo |
| Maintainers | bubkoo |
| Keywords | hash, hex, random, randomly, randomize, chance, test, dice, mock |

## Links

- npm: https://www.npmjs.com/package/random-hexhash
- Repository: https://github.com/mock-end/random-hexhash
- Homepage: https://github.com/mock-end/random-hexhash#readme
- Issues: https://github.com/mock-end/random-hexhash/issues
- npm.io page: https://npm.io/package/random-hexhash

## Dependencies (3)

- [to-length](https://npm.io/package/to-length.md) ^1.0.1
- [random-strr](https://npm.io/package/random-strr.md) ^1.0.0
- [object-assign](https://npm.io/package/object-assign.md) ^4.0.1

## Alternatives

- [duck](https://npm.io/package/duck.md) — 4.2M weekly downloads
- [ava](https://npm.io/package/ava.md) — 560.2K weekly downloads
- [storybook-addon-module-mock](https://npm.io/package/storybook-addon-module-mock.md) — 71.7K weekly downloads
- [@ethereum-waffle/mock-contract](https://npm.io/package/@ethereum-waffle/mock-contract.md) — 40.0K weekly downloads
- [aws-elasticsearch-connector](https://npm.io/package/aws-elasticsearch-connector.md) — 37.4K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2016-04-26
- 0.0.0 — 2016-04-25

## README

# random-hexhash

> Return a random hex hash.

[![MIT License](https://img.shields.io/badge/license-MIT_License-green.svg?style=flat-square)](https://github.com/mock-end/random-hexhash/blob/master/LICENSE)

[![build:?](https://img.shields.io/travis/mock-end/random-hexhash/master.svg?style=flat-square)](https://travis-ci.org/mock-end/random-hexhash)
[![coverage:?](https://img.shields.io/coveralls/mock-end/random-hexhash/master.svg?style=flat-square)](https://coveralls.io/github/mock-end/random-hexhash)


## Install

```
$ npm install --save random-hexhash 

## Usage

```js
var randomHash = require('random-hexhash');

// API
// - randomHash([options]);

// options
// - length
// - casing
```

By default, the hash is lowercase and 40 hex characters long (same as a git commit hash).

```js
randomHash();     
// => 'e5162f27da96ed8e1ae51def1ba643b91d2581d8' 
```

Optionally specify a length:

```js
randomHash({length: 15});     
// => 'c28f57cb599ada4' 
```

Optionally specify casing to get a hash with only uppercase letters rather than the default lowercase:


```js
randomHash({casing: 'upper'});     
// => '3F2EB3FB85D88984C1EC4F46A3DBE740B5E0E56E' 
```


## Related

- [random-uuid](https://github.com/mock-end/random-uuid) - Return a random uuid.
- [random-identity](https://github.com/mock-end/random-identity) - Return a random ID.
- [random-dx](https://github.com/mock-end/random-dx) - Return a value equal to the roll of a die.
- [random-normal](https://github.com/mock-end/random-normal) - Return a normally-distributed random variate.
- [random-rpg](https://github.com/mock-end/random-rpg) - Return an array of dice values.
- [random-file](https://github.com/mock-end/random-file) - Return a random file name with random extension.
- [random-semver](https://github.com/mock-end/random-semver) - Return a random version.

## Contributing

Pull requests and stars are highly welcome.

For bugs and feature requests, please [create an issue](https://github.com/mock-end/random-hexhash/issues/new).

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