minilint
is a fast and small linter.
It is intended to encourage modularity.
It lints JavaScript with the following rules:
- Max 500 lines per file
- Max 80 chars per line
- Max 40 lines per code block (function, array, etc)
- Use two spaces, not tabs
- Max six spaces at the beginning of a line
- No end-of-line operators or semicolons
- No opening
(
or[
at the start of a line - Strict mode
I'm experimenting with using this on my projects. Feel free to use this as well, or not.
npm install -g minilint
minilint <path1> <path2> <...>
If no arguments are passed,
minilint will automatically include **/*.js
and exclude node_modules/**
, coverage/**
, and **/*.min.js
.
--help -h: show help
--verbose -v: enable verbose logging
--exclude -e: exclude all paths appearing after this option
minilint
minilint file.js
minilint file.js --verbose
minilint file1.js file2.js file3.js
minilint "**/*.js" --exclude "node_modules/**"
minilint "**/*.js" -v -e "node_modules/**"
MIT