aster-parse

2019-09-13

Centralized code parsing for aster.

aster-parse

NPM versionBuild Status

Centralized code parsing for aster.

Usage

This is mostly internal module that you don't want to use directly but rather as part of aster-src. However, you should use it directly when developing bindings for external build systems.

API

parse(options)

options.loc

Type: BooleanDefault: true

Location tracking (required for source maps; common option for all the parsers).

options.*

Any other options for parsers being used (see corresponding documentation of each parser).

parse.registerParser(extension, parser)

Method for registering parser as processor for any files with given extension:

var parse = require('aster-parse');
parse.registerParser('.coffee', require('aster-parse-coffee'));

Please note that parsers published under name in format 'aster-parse-<extension>'do not require explicit registration.

License

MIT License

Repository

asterjs/aster-parse


上一篇:aster-parse-js
下一篇:aster-src
相关教程
关注微信

扫码加入 JavaScript 社区

相关文章

首次访问,需要验证
微信扫码,关注即可
(仅需验证一次)

欢迎加入 JavaScript 社区

号内回复关键字:

回到顶部