buxlabs / abstract-syntax-tree

A library for working with abstract syntax trees.
MIT License
110 stars 13 forks source link

Expose optimization methods directly #92

Closed emilos closed 4 years ago

emilos commented 4 years ago

Right now you can only import optimizations method in the following way:

const binaryExpressionReduction = require('abstract-syntax-tree/src/optimizations/binaryExpressionReduction')

it would be much nicer to just import them directly:

const { binaryExpressionReduction } = require('abstract-syntax-tree')

README should be updated as a part of this change