diff --git a/acorn.js b/acorn.js index 1ae8c6bbd2..878ea365db 100644 --- a/acorn.js +++ b/acorn.js @@ -15,7 +15,7 @@ // PARSER - var defaultOptions = { + var defaultOptions = exports.defaultOptions = { ecmaVersion: 5, strictSemicolons: false, allowTrailingCommas: true, diff --git a/index.html b/index.html new file mode 100644 index 0000000000..8447e9fe4f --- /dev/null +++ b/index.html @@ -0,0 +1,31 @@ + + + + Acorn + + + +

Acorn

+ +

(This is a temporary placeholder project page. Better is to come in +the future.)

+ +

Acorn is a tiny, fast JavaScript parser written in JavaScript. If +defines acorn.parse, which, when given a string and an +optional options argument, will spit out an abstract syntax tree.

+ +

The output conforms largely to +the Mozilla +parser API with the caveat that non-ECMAscript features +(let, yield, inline XML, etc) are not +supported, and that node start/end +information is attached directly to the nodes themselves, rather than +wrapped in another object and attached as a loc property.

+ +

See acorn.defaultOptions for the kind of options that +the parser supports.

+ +

Get the code and report bugs on +the Github page.