eslint-plugin-jsdoc
eslint-plugin-jsdoc copied to clipboard
Automatic Line Breaks
Prettier automatically breaks up long lines of code. This is fantastic, and saves developers tremendous amounts of time. Anyone who has used Prettier for a while knows how much of a drain it is to do this manually.
However, Prettier doesn't currently break up long lines on JSDoc comments.
For example, the following JSDoc comment:
Should be instead formatted like this:
If this plugin could perform this transformation for me automatically when I save the file, it would save me an enormous amount of time.
Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.
I made this rule here: https://github.com/IsaacScript/isaacscript/blob/main/packages/eslint-plugin-isaacscript/docs/rules/format-jsdoc-comments.md
Excellent! Feel free to submit your tool to awesome-jsdoc and awesome-eslint and/or submit as a PR to eslint-plugin-jsdoc
. If not the latter, feel free to close the issue. Thanks for sharing!
It's probably not a good fit for JSDoc since it uses the same code to auto format line comments too.
Ok, FWIW, I've listed your tool at https://github.com/brettz9/awesome-jsdoc