Open nene opened 8 years ago
I absolutely agree, and I apologize for the absence of good documentation. I've tried to keep the API simple enough that it can be used without knowledge of the fine details, but that excuse is ringing less and less true as time goes on.
I'm not sure when I'll have time to write up truly adequate documentation, but I would absolutely take a PR that added a link to options.js
to README.md
, if you have time.
Just some JSDoc would help a lot. The code already is commented, but not with JSDoc.
Every time I fiddle with Recast API I have to dig through the source code to find out which methods are available and which configuration options are possible.
run()
,types
andvisit()
.recast.print()
orrecast.parse()
or perhaps some other method.recast.print()
returns some object withcode
field... and then somewhere further down the road it turns out that it might also containmap
. Perhaps there's something else useful inside it as well?For start, a link from README to
options.js
would be great.I'm open to submitting a PR, though I don't really know all the aspects.