message: Expose operations to transform AST and parse once
diff: @@ -14,7 +14,9 @@ export {
  traverseNode,
  traversePath,
  parseAndTraverseCode,
  + parse,
  transform,
  + transformAST,
  transformCopy,
  Transformed,
  AST
  @@ -31,6 +33,17 @@ function transform(code: Code, options: TraverseOptions): Transformed {
  };
  }
  +function transformAST(ast: AST, options: TraverseOptions): Transformed {
  + const code = recast.print(ast).code;
  + const newAst = traverseAST(ast, options);
  + const newCode = recast.print(newAst).code;
  +
  + return {
  + code: newCode,
  + hasCodeChanged: standardizeEOL(newCode) !== standardizeEOL(code)
  + };
  +}
  +
  function standardizeEOL(code: Code): Code {
  return code.replace(/\r/g, "");
  }
  