cljsinfo / cljs.info

ClojureScript website
http://cljs.info
MIT License
96 stars 9 forks source link

Generate cljsdoc files for attributes derived from code #28

Closed shaunlebron closed 9 years ago

shaunlebron commented 9 years ago

Create cljsdoc files for following attributes:

oakmac commented 9 years ago

Just a quick note: I'm not sure we need to generate text files for these so much as just the data format to be combined with docs.json.

The idea behind the .cljsdoc files was to be the "one source of truth" for the markdown documentation and related functions, using simple text files so it could be managed with git and existing tools.

I think the "one source of truth" for the things listed in this issue should be the actual source code, and we should have a function that generates a source-docs.json (or similar) file from the ClojureScript source directly.

shaunlebron commented 9 years ago

I think the idea behind the .cljsdoc files is also that it is both human-readable and easily parseable. So the only difference between having the tool generate cljsdoc or json data is that we can read cljsdoc more easily to verify what it's doing. Trying to view a multiline source string compressed to a single line in json would be annoying.

I'll generate a file to hold the parsed metadata for each symbol, so we can immediately check this generated data as easily as checking the manually written cljsdocs. High visibility of this data will be nice.

oakmac commented 9 years ago

k; sounds good

shaunlebron commented 9 years ago

if you run ./gen-docs.sh at project root, you should see a folder called "docs-generated" with the cljsdocs in it. I'll continue soon with parsing signatures and fixing docstring indentations.

shaunlebron commented 9 years ago

this is done; will create another issue for integrating in Gruntfile