lsegal / yard

YARD is a Ruby Documentation tool. The Y stands for "Yay!"
http://yardoc.org
MIT License
1.94k stars 397 forks source link

Crossreference with other libraries? #855

Closed NobbZ closed 8 years ago

NobbZ commented 9 years ago

Lets say we have some code like this:

# {Fixnum} is from StdLib, {Color::RGB} from gem color
# and all of this is just an example and does not have any
# practical use and these types were choosen randomly
# @param [Fixnum] intensity Intensity of the gray
# @return [Color::RGB] Colorvalue representing that gray
def gray intensity
  # do stuff
end

Is there a way to let yard know about usage of these gems/namespaces and link to their documentation at RubyDoc.info?

phallguy commented 9 years ago

+1

lsegal commented 8 years ago

Closing out old issues.

This is a great idea, but it's extremely complicated to implement for a number of reasons (where is the other doc located at, how to know which library it's referring to, what happens with monkeypatches, perf issues, etc). Unfortunately I don't see a path forward to get this into core any time soon. A plugin would be a great way to get this going without introducing the complexity into YARD core. Note that if rubydoc.info is the goal, this could also just be a layer implemented in http://github.com/docmeta/rubydoc.info directly, where we are much more relaxed about what goes into the core functionality. Also, if the plugin does become popular, pulling it into core could be a discussion.