Sha256: 85ad2f2cd8016ec1468c41072cda0a9a21d31888dea2bc6d1dcae780a492acae

Contents?: true

Size: 1.03 KB

Versions: 6

Compression:

Stored size: 1.03 KB

Contents

module.exports = function (fork) {
    fork.use(require('./es6'));

    var types = fork.use(require("../lib/types"));
    var def = types.Type.def;
    var or = types.Type.or;
    var builtin = types.builtInTypes;
    var defaults = fork.use(require("../lib/shared")).defaults;

    def("Function")
      .field("async", Boolean, defaults["false"]);

    def("SpreadProperty")
      .bases("Node")
      .build("argument")
      .field("argument", def("Expression"));

    def("ObjectExpression")
      .field("properties", [or(def("Property"), def("SpreadProperty"))]);

    def("SpreadPropertyPattern")
      .bases("Pattern")
      .build("argument")
      .field("argument", def("Pattern"));

    def("ObjectPattern")
      .field("properties", [or(
        def("Property"),
        def("PropertyPattern"),
        def("SpreadPropertyPattern")
      )]);

    def("AwaitExpression")
      .bases("Expression")
      .build("argument", "all")
      .field("argument", or(def("Expression"), null))
      .field("all", Boolean, defaults["false"]);
};

Version data entries

6 entries across 6 versions & 3 rubygems

Version Path
ilog-0.4.1 node_modules/ast-types/def/es7.js
ilog-0.4.0 node_modules/ast-types/def/es7.js
ilog-0.3.3 node_modules/ast-types/def/es7.js
locomotivecms-4.0.0.alpha1 app/javascript/node_modules/webpack-addons/node_modules/ast-types/def/es7.js
locomotivecms-3.4.0 app/javascript/node_modules/webpack-addons/node_modules/ast-types/def/es7.js
dragonfly_puppeteer-0.1.0 node_modules/webpack-addons/node_modules/ast-types/def/es7.js