JSDOC reference function not in a class

Viewed 37

If I have two functions in (neither inside an explicit class) in the following structure

A/foo.ts

B/bar.ts

Where

bar.ts has

export const happy()...

And foo.ts has

/** @see happy /*

How can I see the correct linkage to bar#happy?

I tried borrows and and alias to no success.

1 Answers

Just import the type only like the following snippet. import types are removed when compiled to JavaScript so you're safe if this is not intended.

foo.ts

import type { happy } from './bar'

/** @see happy */

enter image description here

Related