Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

internal and external link in same section break #1100

Closed
1 task done
FranklinYu opened this issue Jun 24, 2017 · 1 comment
Closed
1 task done

internal and external link in same section break #1100

FranklinYu opened this issue Jun 24, 2017 · 1 comment

Comments

@FranklinYu
Copy link

Steps to reproduce

  1. In empty folder, create a file lib/test.rb with content

    # {#both} internal and {External}[http://www.rubydoc.info/] breaks.
    def both
      nil
    end
    
    # {#inner_only} works.
    def inner_only
      nil
    end
    
    # {External only}[http://www.rubydoc.info/] also works
    def external_only
      nil
    end
  2. Run yard at project root.

Actual Output

The section for #both is rendered as

<a href="http://www.rubydoc.info/">#both} internal and {External</a>

(There is nothing interesting in console output, but I can surely provide it if you are interested in it.)

Expected Output

That section should be

<a href="#both-instance_method" title="#both (method)">#both</a>
internal and
<a href="http://www.rubydoc.info/">External</a>

Environment details:

  • OS: macOS 10.12.5 (16F73)
  • Ruby version: 2.4.1
  • YARD version: 0.8.7.6
  • Relevant software dependency/versions: N/A
@FranklinYu
Copy link
Author

It is mentioned in #210 that the documentation is first translated by RDoc, who does not know the {#method} syntax. Since my documentation heavily rely on Yard functionality, supporting RDoc is impossible anyway (thus unnecessary), so I may as well just use Yard’s link (which works as expected).

tarfand77 referenced this issue Jun 28, 2017
Document block for Struct.new if present
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant