# @codedipper/random-code

> Generates a random code.

Latest version **3.1.0** (published 2023-03-05) · MIT license · 0 weekly downloads

## Install

```sh
npm install @codedipper/random-code
pnpm add @codedipper/random-code
yarn add @codedipper/random-code
bun add @codedipper/random-code
```

## Health

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

Positive: has types; esm support; no vulnerabilities.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 3.1.0 |
| Published | 2023-03-05 |
| First published | 2020-11-12 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Dependencies | 0 |
| Unpacked size | 2.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Revvy |
| Maintainers | codedipper |
| Keywords | generator, code, id, random |

## Links

- npm: https://www.npmjs.com/package/@codedipper/random-code
- Repository: https://git.revvy.de/Revvy/random-code
- npm.io page: https://npm.io/package/@codedipper/random-code

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

- 3.1.0 (latest) — 2023-03-05
- 3.0.1 — 2022-08-01
- 3.0.0 — 2022-07-20
- 2.2.1 — 2022-06-03
- 2.2.0 — 2022-06-03
- 2.1.2 — 2021-02-06
- 2.1.1 — 2021-01-01
- 2.1.0 — 2020-12-23
- 2.0.0 — 2020-12-03
- 1.0.2 — 2020-11-15
- 1.0.1 — 2020-11-14
- 1.0.0 — 2020-11-13
- 0.0.3 — 2020-11-12
- 0.0.2 — 2020-11-12
- 0.0.1 — 2020-11-12

## README

# random-code
## About
Generates a random code/id.\
One simple function and zero dependencies.\
Node.js v0.10.0 required for CJS.
## Browser
Simply copy and paste the following tag into your HTML:\
`<script src="https://rc.revvy.de/3.1.0/browser.min.js"></script>`\
Then use the `gen()` function as normal.
## Example
```js
const gen = require("@codedipper/random-code");
// import gen from "@codedipper/random-code";

console.log(gen()); // Will generate ten character code.
console.log(gen(4)); // Will generate four character code.
console.log(gen(4, "0123456789"));
// ^ Will generate four character code with those specific characters.
```

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