cfware / acorn-optional-chaining

Optional Chaining support for Acorn.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Optional Chaining Support for Acorn

NPM version

This is a plugin for Acorn - a tiny, fast JavaScript parser, written completely in JavaScript.

Purpose of this fork

This fork exists to enable compatibility with rollup 2.x. This will be deprecated and archived once compatibility is merged upstream.

Usage

This module provides a plugin which extends the Acorn Parser class to handle optional chaining:

import * as acorn from 'acorn';
import optionalChaining from 'acorn-optional-chaining';

acorn.Parser.extend(optionalChaining).parse('a?.b?.c');

License

This plugin is released under an MIT License.

It was based off the structure of acorn-numeric-separator.

About

Optional Chaining support for Acorn.

License:MIT License


Languages

Language:JavaScript 100.0%