JSPM

aster-parse

0.1.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 12
  • Score
    100M100P100Q46596F
  • License MIT

Centralized code parsing for aster.

Package Exports

  • aster-parse

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (aster-parse) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

aster-parse

NPM version Build 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: Boolean Default: 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