jsdoc-api icon indicating copy to clipboard operation
jsdoc-api copied to clipboard

@see with inline @link not parsed

Open khalyomede opened this issue 6 years ago • 2 comments

Issue

When parsing a bloc of comment containing nested @link in a @see, the see key in the output gives raw links instead of parsing the name of the link and the url.

How to reproduce

Try to parse this following comment:

/**
  * Returns the first (or first nth) element(s) of the array.     * 
  * @param {Integer} options.count=1 - number of element to return
  * @return {*}
  * @throws {Error} if the option "count" is not an integer
  * @since 0.1.0
  * @see {@link https://github.com|View source}
  * @see {@link https://github.com|View tests}
  */

Expected value

Something like:

see:
  [ links: [  { url: 'https://github.com',
                name: 'View source' },
              { url: 'https://github.com',
                name: 'View tests' } ] ]

Actual value

see:
   [ '{@link https://github.com|View source}',
     '{@link https://github.com|View tests}' ]

Version used to fill this issue

4.0.3

khalyomede avatar May 10 '18 12:05 khalyomede

hi, does this case work as expected in jsdoc?

75lb avatar May 15 '18 21:05 75lb

Hi @75lb , seems to yep

jsdoc-example-see-links

The code that originated this doc:

/**
 * @see {@link foo} for further information.
 * @see {@link http://github.com|GitHub}
 */
function test() {
    
}

khalyomede avatar May 15 '18 21:05 khalyomede