js-calculation
v2.0.7
Published
solving the problem of javaScript computing accuracy loss
Downloads
40
Maintainers
Readme
matters needing attention
Due to release errors, js-accuracy is changed to js-calculation from now on!
This only applies to small projects, and if you're building a large project, recommend that you use math.js to meet your needs!
You need to use Babel with it
install calculation.js
npm install js-calculation
use calculation.js
import calc from 'js-calculation'
calc('0.1 0.1 *') // 0.01
calc('0.1 0.1 * 0.1 -') // -0.09
calc('0.1 0.1 * 0.1 - 0.1 0.1 * +') // -0.08