JSDoc @link not resolved across modules
See original GitHub issueBug Report
While verifying https://github.com/microsoft/vscode/issues/119357
🔎 Search Terms
- link
- export
- modules
🕗 Version & Regression Information
- I was unable to test this on prior versions because it did not previously exist
⏯ Playground Link
💻 Code
// @filename: a.ts
import { Model } from './b';
/**
* {@link Model}
*/
// @filename: b.ts
export class Model {}
🙁 Actual behavior
@link Model
is not clickable
🙂 Expected behavior
I expected to be able to click on @link Model
Issue Analytics
- State:
- Created 2 years ago
- Reactions:7
- Comments:5 (4 by maintainers)
Top Results From Across the Web
JSDoc3 does not generate hyperlinks to namespaces in NodeJS
I have found out my issue was related to the usage of JSDoc with CommonJS (NodeJS). After several hours of googling and trial...
Read more >Documentation - ECMAScript Modules in Node.js - TypeScript
js ecosystem is built on a different module system called CommonJS (CJS). Interoperating between the two module systems brings large challenges, with many...
Read more >Use JSDoc: {@link}
The {@link} inline tag creates a link to the namepath or URL that you specify. When you use the {@link} tag, you can...
Read more >Declaration References - TypeDoc
Reference Scope. If no module source is specified, by default component paths are resolved relative to the scope where they are declared (note:...
Read more >rollup.js
Importing CommonJS · Publishing ES Modules ... Do not follow symlinks when resolving files --no-sanitizeFileName Do not replace invalid characters in file ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This had a bit of chatter about whether expanding the scope to all identifiers is the right call, so I’ll wait till @sandersn is back to chat about that
Otherwise, we’ll make the un-used import as used if it’s in the
@link
After discussing this with @orta, we switched our opinions. Now I think that expanding the scope to all identifiers is the right call and he doesn’t. However: it would be difficult to decide on the precise semantics and difficult to implement efficiently, so I don’t think it’s worthwhile right now.
What should work is import references:
import('./b').Model
. I don’t think that@link
even parses this reference right now.Edit: @mjbvz beat me to it: #43950