# @node-oauth/formats

> Validate ascii and unicode values.

Latest version **1.1.0** (published 2026-01-26) · MIT license · 0 weekly downloads

## Install

```sh
npm install @node-oauth/formats
pnpm add @node-oauth/formats
yarn add @node-oauth/formats
bun add @node-oauth/formats
```

## Health

**Score 45/100 (D)** — status: stable.

Positive: no vulnerabilities.

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

## Facts

| | |
|---|---|
| Version | 1.1.0 |
| Published | 2026-01-26 |
| First published | 2021-12-11 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 9.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Maintainers | jkuester, happyzombies |
| Keywords | unicode, validate, utf-8, ascii, vschar, uri, uchar, nqschar, nqchar, nchar |

## Links

- npm: https://www.npmjs.com/package/@node-oauth/formats
- Repository: https://github.com/node-oauth/formats
- Homepage: https://github.com/node-oauth/formats#readme
- Issues: https://github.com/node-oauth/formats/issues
- npm.io page: https://npm.io/package/@node-oauth/formats

## 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.1.0 (latest) — 2026-01-26
- 1.0.0 — 2021-12-11

## README

# @node-oauth/formats

Minimal, [RFC 6749](https://datatracker.ietf.org/doc/html/rfc6749#appendix-A)
compliant ascii and unicode validator.

This package is intended to be used with a OAuth2 server, like 
[@node-oauth/node-oauth2-server](https://github.com/node-oauth/node-oauth2-server)
, but can also be used with any other project, that shares the same 
requirements.

## Install

```bash
$ npm install @node-oauth/formats
```

## Usage

```js
const isFormat = require('@node-oauth/formats')

isFormat.nchar('Hello, World!') // false
isFormat.nqchar('Hello, World!') // true
```

For detailed usage see the [API docs](./API.md)

## Test

```sh
npm install
npm run lint            # run esline in check mode
npm run lint:fix        # run esline in check mode
npm run test            # run test once
npm run test:coverage   # run tests with coverage report
```

## License

This project has been outsourced from 
[@node-oauth/node-oauth2-server](https://github.com/node-oauth/node-oauth2-server)
, which is a fork from [oauth2-server](https://github.com/oauthjs/node-oauth2-server)
. The licence remains MIT, see [our license file](./LICENSE).

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