0.0.1 • Published 1 year ago

chart-scale v0.0.1

Weekly downloads
-
License
MIT
Repository
-
Last release
1 year ago

A tool for calculating the scale range of a chart

Install

npm install chart-scale

Import

import getChartScale from 'chart-scale'
import { getChartScale } from 'chart-scale'

Use

const { max, min, interval } = getChartScale(5.3, -0.9, 7)
console.log(max, min, interval)
// {max: 6, min: -1, interval: 1}
0.0.1

1 year ago