Skip to content

Latest commit

 

History

History
43 lines (30 loc) · 1.25 KB

README.md

File metadata and controls

43 lines (30 loc) · 1.25 KB

acorn-node

Acorn with defaults for syntax parity with recent Node versions.

npm travis standard

Install

npm install acorn-node

Usage

var acorn = require('acorn-node')

The API is the same as acorn but with different defaults, to match Node modules:

  • ecmaVersion: 2022
  • allowHashBang: true
  • allowReturnOutsideFunction: true
var walk = require('acorn-node/walk')

The Acorn syntax tree walker. Comes preconfigured for the syntax plugins if necessary. See the acorn documentation for details.

License

The files in the repo root and the ./test folder are licensed as Apache-2.0.