| Page 1 of 1 | [ 5 posts ] |
|
I've started to use yuidocjs to build javascript documentation and it is fantastic. I'm wondering what is the recommended way to get the information about classes I've extended in the YUI3 library (e.g. Base, Widget, etc) into my widget's docs without having all of YUI3's docs included with my own as well.
|
|
Peter, currently I am waiting on IO to be functional again in YUI on Node. Once that works, you will be able to set a config option like this in your yuidoc.json file (this does not work yet):
Code: { external: { data: 'http://yuilibrary.com/yui/docs/api/data.json' } } Then when YUIDoc builds the docs, it will fetch and mix this external data with the internal parsed data crosslinking those objects out to our site. |
|
Will/Could this support multiple external sources? e.g. I have an app whose components are built from a combination of widget_library_a, gallery_module_b, and yuilibrary.
|
|
If you don't mind hacking your node_modules until that's fixed, you can edit yuidocjs to allow you to point at a local data.json and a remote webhost.
In your yuidocjs module directory, go open lib/builder.js and comment out the line that looks like this: Code: info.base = path.dirname(path.resolve(info.data)); Then, you should be able to do this in your doc config: Code: { external: { data: "path/to/data.json", base: "http://yuilibrary.com/yui/docs/api" } } As a note: this won't include inherited methods or properties from the external modules, and the @use keyword won't link remotely. It will provide remote links to the classes you're extending. As a further note: I would find the above case--pointing at a local data.json and a remote documentation source--immensely useful. The data.json file is 3.6 meg and it needs to be downloaded any time you want to build the docs, which takes a non-zero amount of time. Pointing at a local json file and assuming it's up-to-date would be a handy trick. |
|
I'll likely support data as an array of config's & I will likely add a cache to it as well Only fetching the headers for a last modified stamp before downloading a new version.
I'm hoping to be able to get this back into the system next week, this week I'm finishing up IO in Node so I will have something to work with |
| Page 1 of 1 | [ 5 posts ] |
| You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum |
© 2006-2013 Yahoo! Inc. All rights reserved.
All code on this site is licensed under the BSD License unless stated otherwise.
About This Site · Security Contact Info
Powered by phpBB® Forum Software © phpBB Group