chance-class-name

1.0.1 • Public • Published

chance-class-name Build Status

A Chance.js mixin to generate class names.

Class names are generated according the W3C CSS spec.

Install

NPM

$ npm i chance-class-name

Yarn

$ yarn add chance-class-name

Usage

import Chance from 'chance';
import className from 'chance-class-name';
 
const chance = new Chance();
 
chance.mixin({
    className
});
 
chance.className();

By default, chance-class-name will return a randomly generated class name.

Class names will be between 1 and 25 characters long.

Example: M-oYLdbPVMpbhjGrsLH

License

MIT © Michael Novotny

Package Sidebar

Install

npm i chance-class-name

Weekly Downloads

2

Version

1.0.1

License

MIT

Unpacked Size

4.06 kB

Total Files

5

Last publish

Collaborators

  • manovotny