Skip to content
jsigbizPublic

About

No description, website, or topics provided.

Resources

Stars

6 stars

Watchers

2 watching

Forks

Repository files navigation

parser

a JavaScript module for parsing jsig

install

$ npm install jsig

example

var parse = require('jsig')
var ast = parse('reduce: (array: Array, (accumulated: Any, elem: Any) => Any, seed: Any) => Any')
console.log(ast, null, 2)
{
  "type": "program",
  "statements": [
    {
      "type": "assignment",
      "identifier": "reduce",
      "typeExpression": {
        "type": "function",
        "args": [
          {
            "type": "typeLiteral",
            "name": "Array",
            "builtin": true,
            "label": "array",
            "optional": false
          },
          {
            "type": "function",
            "args": [
              {
                "type": "typeLiteral",
                "name": "Any",
                "builtin": true,
                "label": "accumulated",
                "optional": false
              },
              {
                "type": "typeLiteral",
                "name": "Any",
                "builtin": true,
                "label": "elem",
                "optional": false
              }
            ],
            "result": {
              "type": "typeLiteral",
              "name": "Any",
              "builtin": true,
              "label": null,
              "optional": false
            },
            "thisArg": null,
            "label": null,
            "optional": false
          },
          {
            "type": "typeLiteral",
            "name": "Any",
            "builtin": true,
            "label": "seed",
            "optional": false
          }
        ],
        "result": {
          "type": "typeLiteral",
          "name": "Any",
          "builtin": true,
          "label": null,
          "optional": false
        },
        "thisArg": null,
        "label": null,
        "optional": false
      }
    }
  ]
}

license

see LICENSE

About

No description, website, or topics provided.

Resources

Stars

6 stars

Watchers

2 watching

Forks

Releases

Packages

Used by

Contributors

Languages