Closed shreyankg closed 8 years ago
Sorry for the lack of response on this.
There have been efforts to dump to JSON in the past, specifically when working on refactors of the templating engine to work more like a single page app. The biggest issue was speed and size, because a single JSON document is actually pretty hefty and slow to load. If performance benchmarks showed that JSON was similar in speed and size, it would be on the roadmap, but if it's significantly slower or larger I don't know that it would be part of core.
Note that you can always write these things as plugins. The Registry has a RegistryStore backend which actually manages the data on disk, and that can be swapped out (or should be swappable).
Closing as an answered question. Patches would be looked at for a YARD Registry to json exporter option, though as suggested, starting it as a plugin and opening a PR only after it is stable is the better path, I believe. I'm open to accepting PRs that fix any roadblocks in making this a plugin, if there are any.
I'm working on a fork of yard which would take an option to dump the .yardoc database into JSON instead of Marshal. I'll be pushing commits to my fork in sometime, but before I do that, I wanted to understand if adding such functionality is part of yard's roadmap or is there a possibility of it's inclusion ?