make-tints
Version:
[](https://www.npmjs.com/package/make-tints)
32 lines (22 loc) • 943 B
Markdown
<p align="center">
<img src="images/make-tints.png" height="64">
<p align="center">The simplest color tone function for JS</p>
[](https://www.npmjs.com/package/make-tints)
[](https://github.com/barelyhuman/make-tints/actions/workflows/ci.yml)
[](https://packagephobia.com/result?p=make-tints)
## Install
```
npm i make-tints
```
[See it in action →](https://barelyhuman.github.io/make-tints)
## Usage
```js
import {tint} from 'make-tints'
const tintBy = tint('#000')
tintBy(-20) //=> 000000 darker tints can be achieved by using negative percentages
tintBy(20) //=> 333333
tintBy(40) //=> 666666
tintBy(60) //=> 999999
```
## License
[MIT](./LICENSE) License © 2022 [Reaper](https://github.com/barelyhuman)