Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

156
Views
JSDOC @property before class versus @type at declaration for class properties

In my class I want to document its properties so that they're noted when hovering over the class itself, but I also want my documentation to show up when hovering the properties themselves:

/**
 * Example class
 * @property {string} foo - Example property
 */
class bar {
    constructor(){
       /**
        * Example property
        * @type {string}
        * @public
        */
       this.foo = 'foo';
    }
} 

I need to have it similar to this to get the desired result of having the info about this.foo show up when hovering both the class/constructor and this.foo itself.

This feels redundant and I feel like there must be a more concise way to get the desired result.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!