benjamn / recast

JavaScript syntax tree transformer, nondestructive pretty-printer, and automatic source map generator
MIT License
5.01k stars 350 forks source link

Does recast support custom printers? #219

Open platinumazure opened 9 years ago

platinumazure commented 9 years ago

Is it possible to specify that a different printer (which would conform to the same API and support the same type of AST) should be used when printing code?

As an example, if I had to print code to match the jQuery preferred style, I would need a printer that adds whitespace to the inside of all bracket tokens (among other things).

goodmind commented 5 years ago

Same issue with https://github.com/benjamn/ast-types/issues/286