Skip to content

Commit

Permalink
build(lint-staged): add doctoc to pre-commit build process
Browse files Browse the repository at this point in the history
  • Loading branch information
Xunnamius committed Oct 20, 2022
1 parent 81f5f8f commit fa4f9ee
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lint-staged.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,13 @@
'use strict';

/**
* These scripts are the constituent parts of the `npm run format` command.
*/
module.exports = {
'*.md': 'npx remark --output --frail',
'*.md': [
'npx remark --output --ignore-path=.prettierignore --silently-ignore',
'npx doctoc --no-title --maxlevel=3 --update-only'
],
'package.json': 'sort-package-json',
'*': 'prettier --write --ignore-unknown'
};

0 comments on commit fa4f9ee

Please sign in to comment.