Giter Site home page Giter Site logo

vscode-docthis's People

Contributors

akiravoid avatar dominikschreiber avatar geekpulp avatar icfjoeld avatar ifgx avatar jamietre avatar joelday avatar kou029w avatar manuth avatar mbaric1 avatar mprobber avatar mredbishop avatar oouo-diogo-perdigao avatar theopendevproject avatar vapits avatar waldyrious avatar warpdesign avatar zhanghaocong avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

vscode-docthis's Issues

Support private class members

When trying to generate documentation for a private member, it just documents the class:

class Foo {
    #bar (a, b){
        // ...
    }
}

Expected:

class Foo {

    /**
     * 
     * @param {*} a
     * @param {*} b
     */
    #bar (a, b){
        // ...
    }
}

Actually:

/**
 * 
 * @class Foo
 */
class Foo {
    #bar (a, b){
        // ...
    }
}

Stared. Vue *.vue support plz !!

Vue2 and Vue3 support plz!
Like:

//Vue2
methods: {
   /**
    * something here!
    */
    func(paramA, paramB){
        //something here
       return ;
  }
}

This is an awesome plugin, to the point where I can't even imagine my life without it !
I believe this plugin will become very popular in the future.

Document after typing "/**" and pressing TAB

Is it possible to docuemtn the code after typing "/**" and then pressing TAB instead of having to do CTRL + ALT + D? Like replace the default documentation with this extension's documentation.

Line above gets deleted when using extension

First of all, thank you SO much for the wonderful extension!

Description:
Hello there, there seems to be a rather annoying issue. Whenever you use the extension the line above gets overwritten, if you had something declared, it gets deleted.

Steps to reproduce:

  1. Have two lines of code, for instance:
const someVar: string; // <-- This will be deleted
const someOtherVar: string; // <--Try documenting this
  1. Right click someOtherVar declaration and select "Document This"
  2. Observe the line above (someVar) gets deleted.

Expected result:
Line should be respected and stay while documenting the intended line.

Actual:
Line above gets deleted:

  /**
   *
   *
   * @type {string}
   */
  var someOtherVar: string; 

Workaround:
Easiest thing is to insert a line break in between them and then document. This is rather annoying.

Documenting a destructuring parameter is wrong

prefer

/**
 * Assign the project to an employee.
 * @param {Object} employee - The employee who is responsible for the project.
 * @param {string} employee.name - The name of the employee.
 * @param {string} employee.department - The employee's department.
 */
Project.prototype.assign = function({ name, department }) {
    // ...
};

but get

/**
 *
 *
 * @param {*} { name, department }
 * @return {*} 
 */
Project.prototype.assign = function({ name, department }) {
    // ...
};

https://jsdoc.app/tags-param.html Documenting a destructuring parameter

Interface fields

Dear All,

How can I create interface fields with this extension into jsdoc?

Current result:

/**
 *
 *
 * @interface WorksOfDaysOfEmployment
 */
interface WorksOfDaysOfEmployment {
    employment: components["schemas"]["EmploymentRelationshipDTOForClient"],
    worksOfDays:WorksOfDay
}

Goal to be achieved:

/**
 * @interface WorksOfDaysOfEmployment
 * @property {components["schemas"]["EmploymentRelationshipDTOForClient"]} employment - Az alkalmazotti kapcsolat.
 * @property {WorksOfDay} worksOfDays - Az egyes napokon végzett munkák tömbjei.
 */
interface WorksOfDaysOfEmployment {
    employment: components["schemas"]["EmploymentRelationshipDTOForClient"],
    worksOfDays:WorksOfDay
}

Current settings:
image

this extension is intercepting keystrokes meant for another extension

I'm the author of the Spin2 VSCode Extension.

I also hook ctrl+alt-D. My extension is active for .spin and .spin2 files. When both of our extensions are installed this one (doc this) intercepts the ctrl+alt-D request and generates an error saying it only supports javascript and typescript. Then my extension doesn't get the keystroke.

How about you only intercept the keystroke if it's against one of the document suffixes you support? Alternatively, at least let the keystroke be passed on to other extensions!

Vue bug?

Doesn't work for .vue components?

try to Document this,

methods: {
    clear() {
      this.clearData()
      this.$router.push('/wwwww')
      ......
      }
    }

and getting error

Sorry! 'Document This' wasn't able to produce documentation at the current position.

Apply globally

How can I apply the JsDocs to full projects at once? It can be with this extension or a CLI command.

Allow @class annotation to be optional in ES5 class

When generating a JSDoc for an ES5 class, this is generated by default:

/**
 * 
 * @class Bar
 */
class Bar  {}

The problem is, in JSDoc 3, ES5 classes are automatically recognized. Doing this generates 2 Bar class declarations.

Adding the @Class as an optional generator would fix it.

Cannot produce documentation for `*** = function(a, b) { } `

Code:

SomeObject.prototype.method = function(a, b) {
    // ...
};

Expected:

/**
 * 
 * @param {*} a
 * @param {*} b
 */
SomeObject.prototype.method = function(a, b) {
    // ...
};

Actually get an ERROR.

Sorry! 'Document This' wasn't able to produce documentation at the current position.

image

Vue files are broken

Works great in .js and .ts files, but in .vue files the extension fails with Sorry! 'Document This' wasn't able to produce documentation at the current position.

For example, this computed property:

  private get assetDisplayName(): string {
    if (asset.enabled) {
      return 'enabled';
    }
    return 'disabled';
  }

I see in extension.ts that you are supporting Vue files, but it seems like something is broken maybe?

Thank you 🙏

Type annotation in JSDoc is redundant in Typescript code. (no-redundant-jsdoc)

Hi there,

When I set IncludeTypes to false inside of the settings of the plugin, the @returns still has type annotation for a "any" object type like so:

/**
 * @returns {*}
 */

Is there a way to remove the {*} part? Since typescript is generating warnings because of this.

Please let me know what I can do to generate proper typescript JSDoc for my code.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.