microsoft / vscode-comment

Adds simple jsdoc comments for the parameters of a selected function signature
Other
72 stars 36 forks source link

Comment isn't properly indented #2

Closed mathias-lundin closed 8 years ago

mathias-lundin commented 8 years ago

Generated comments are not indented the same as the function.

/**
 * @param  {any} someParam
 */
        function myFunc(someParam) {
            return true;
        }
stevencl commented 8 years ago

Thanks for reporting, I'll take a look and see what I can do.

stevencl commented 8 years ago

I pushed a fix in commit 20d8bd. I simply count the number of leading whitespace characters in the line containing the function signature and then indent the comment with the same number of spaces.

I'll close this issue but please let me know if the fix doesn't work as you expect it to.