UNPKG

oidc-provider

Version:

OAuth 2.0 Authorization Server implementation for Node.js with OpenID Connect

10 lines (7 loc) 184 B
import { nanoid, customAlphabet } from 'nanoid'; export default (length, charset) => { if (charset) { return customAlphabet(charset, length)(); } return nanoid(length); };