npm.io
1.1.0 • Published 5 years ago

@crayon.js/lite

Licence
MIT
Version
1.1.0
Deps
0
Size
17 kB
Vulns
0
Weekly
0
Stars
57
DeprecatedThis package is deprecated

Crayon.js Lite


About

Crayon.js Lite was created for users who won't use all of crayon.js features aka don't want to bloat their programs

It provides the same API as crayon.js however it removes some features

Installation

npm install @crayon.js/lite #yarn add @crayon.js/lite

Differences

  • No CSS Keywords support.
    • Main thing about lite version is that it's stripped from css keywords, this means that:
      import crayon = require('@crayon.js/lite')
      
      // crayon.olive('This would throw an error')
      // crayon.keyword('olive')('This would throw an error also')
      crayon.red('This still works')
      crayon.bold('This still works')
      crayon.red.bold('This still works')
      crayon.rgb(255,135,0)('this still works')
  • Lower require times ~6/7ms -> ~4/5ms
  • 2-3x Lower package size
Learn more about crayon.js here

Contributing

Feel free to fork, add commits and pull requests
To-do List
  • Add jest coverage tests

Licensing

This project is available under MIT License conditions.

Keywords