Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nothingrandom/varops
Object for parsing javascript operators from variables
https://github.com/nothingrandom/varops
Last synced: 17 days ago
JSON representation
Object for parsing javascript operators from variables
- Host: GitHub
- URL: https://github.com/nothingrandom/varops
- Owner: nothingrandom
- License: mit
- Created: 2020-01-22T17:00:01.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2023-09-22T17:07:06.000Z (about 1 year ago)
- Last Synced: 2024-10-07T23:20:12.573Z (about 1 month ago)
- Language: JavaScript
- Size: 832 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# varops
![Travis (.com)](https://img.shields.io/travis/com/nothingrandom/varops)
> Object for parsing javascript operators from variables## Install
``` bash
$ yarn add varops
$ npm install varops
```## Usage (ES6 imports)
``` js
import varops from 'varops';const plus = '+';
const maths = varops[plus](1, 10);console.log(maths); // 11
```## Support for these operators;
`+` `-` `*` `/` `**` `%`## License
MIT © [Benjamin Grant](https://nothingrandom.com)