UNPKG

numenor

Version:

Customizable, safe evaluator of JavaScript-like expressions.

41 lines (23 loc) 934 B
# numenor [![npm version](https://badge.fury.io/js/numenor.svg)](https://badge.fury.io/js/numenor) Customizable, safe evaluator of JavaScript-like expressions. _**WARNING:** Still highly experimental, do not use in production!_ ### Installing Simply add `numenor` as a dependency via Yarn (or NPM): ``` yarn add numenor ``` Then import `ExpressionEvaluator` class in your code: ``` import { ExpressionEvaluator } from 'numenor'; const evaluator = new ExpressionEvaluator(); evaluator.evaluate('2 + 2 / 2'); // -> 3 ``` ### API _TODO: WRITE ME_ ## Versioning This project uses [SemVer](http://semver.org/) for versioning. For the versions available, see the [tags on this repository](https://github.com/raleksandar/numenor/tags). ## Is it any good? ~~Yes.~~ It will be... ## License This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details