elijah-potter / harper

The Grammar Checker for Developers
https://writewithharper.com
Apache License 2.0
1.93k stars 35 forks source link

`harper-ls` doesn't check lines that start with JSDoc tags #265

Open mcecode opened 3 weeks ago

mcecode commented 3 weeks ago

When harper-ls checks JSDoc comments, it seems to ignore lines that start with JSDoc tags so some descriptions won't be linted. For example, in the snippet below, harper-ls doesn't indicate that "zpelling" is wrong.

/**
 * @param {string} message - Wrong zpelling
 */
function print(message) {
  console.log(message);
}

It works when the description is moved to the next line, like so:

/**
 * @param {string} message
 *   Wrong zpelling
 */
function print(message) {
  console.log(message);
}