diff --git a/.eslintrc.yml b/.eslintrc.yml index 1eece14..cf3015f 100644 --- a/.eslintrc.yml +++ b/.eslintrc.yml @@ -1,2 +1,9 @@ root: true -extends: standard +extends: + - standard + - plugin:markdown/recommended +plugins: + - markdown +overrides: + - files: '**/*.md' + processor: 'markdown/markdown' diff --git a/README.md b/README.md index 26d3b93..3a0bb05 100644 --- a/README.md +++ b/README.md @@ -16,8 +16,6 @@ $ npm install content-disposition ## API - - ```js var contentDisposition = require('content-disposition') ``` @@ -28,8 +26,6 @@ Create an attachment `Content-Disposition` header value using the given file nam if supplied. The `filename` is optional and if no file name is desired, but you want to specify `options`, set `filename` to `undefined`. - - ```js res.setHeader('Content-Disposition', contentDisposition('∫ maths.pdf')) ``` @@ -70,8 +66,6 @@ it). The type is normalized to lower-case. ### contentDisposition.parse(string) - - ```js var disposition = contentDisposition.parse('attachment; filename="EURO rates.txt"; filename*=UTF-8\'\'%e2%82%ac%20rates.txt') ``` diff --git a/package.json b/package.json index e11e555..60e9d07 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,7 @@ "eslint": "7.32.0", "eslint-config-standard": "13.0.1", "eslint-plugin-import": "2.25.2", - "eslint-plugin-markdown": "1.0.0-rc.1", + "eslint-plugin-markdown": "2.2.1", "eslint-plugin-node": "11.1.0", "eslint-plugin-promise": "5.1.1", "eslint-plugin-standard": "4.0.0", @@ -36,7 +36,7 @@ "node": ">= 0.6" }, "scripts": { - "lint": "eslint --plugin markdown --ext js,md .", + "lint": "eslint .", "test": "mocha --reporter spec --bail --check-leaks test/", "test-ci": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/", "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/"