callup

0.0.1 • Public • Published

callup

A simple calling parser

Install

Install with npm

$ npm i callup --save

Install with yarn

$ yarn add callup

Example

const expr = 'fn(a+bf, cb(7) + " Snow", w+3+y)';
const callup = require('callup');
console.log(callup.parse(expr));
// =>
// {
//   "name": "fn",
//   "args": [
//     {
//       "op": "+",
//       "left": "a",
//       "right": "bf"
//     },
//     {
//       "op": "+",
//       "left": {
//         "name": "cb",
//         "args": ["7"]
//       },
//       "right": " Snow"
//     },
//     {
//       "op": "+",
//       "left": "w",
//       "right": {
//         "op": "+",
//         "left": "3",
//         "right": "y"
//       }
//     }
//   ]
// }

Package Sidebar

Install

npm i callup

Weekly Downloads

0

Version

0.0.1

License

MIT

Unpacked Size

25.5 kB

Total Files

10

Last publish

Collaborators

  • frge