@alza54/eslint-config-jsdoc

0.6.1 • Public • Published

@alza54/eslint-config-jsdoc

shellcode.team Build Status shellcode-styleguide

Shareable configuration for eslint-plugin-jsdoc.

The main idea of this configuration is to be:

  1. Strict about syntax
  2. Permissive about types (because we use flow for type annotations)
  3. Opened for further extensions

Installation

npm install --save-dev @alza54/eslint-config-jsdoc

or yarn

yarn add -D @alza54/eslint-config-jsdoc

Then, modify your eslint configuration:

{
  "extends": [
    "@alza54/jsdoc"
  ]
}

Done! Later you can modify your configuration to include any extra rules you need.

Code example

This code is considered valid (and beautiful):

/**
 * Imaginary function to take same slices from imaginary pizza.
 * This function is created, because I love pizza.
 *
 * @param pizza - {Array} List of slices.
 * @param numberOfSlices - Number of slices to take away.
 * @returns {Array} What is left of our pizza.
 */
function takeSlices (pizza, numberOfSlices) {
  return pizza.splice(0, numberOfSlices);
}

License

MIT.

Package Sidebar

Install

npm i @alza54/eslint-config-jsdoc

Weekly Downloads

1

Version

0.6.1

License

MIT

Unpacked Size

4.4 kB

Total Files

4

Last publish

Collaborators

  • alza54