diff --git a/.README/processors.md b/.README/processors.md index ab0b03ab1..e5daf220b 100644 --- a/.README/processors.md +++ b/.README/processors.md @@ -9,6 +9,8 @@ The approach below works in ESLint 9. For ESLint 7, please see our [`check-examp The approach requires that we first indicate the JavaScript files that will be checked for `@example` tags. ```js +import getJsdocProcessorPlugin from 'eslint-plugin-jsdoc/getJsdocProcessorPlugin.js'; + export default [ { files: ['**/*.js'], diff --git a/docs/processors.md b/docs/processors.md index 3d1492d02..a588a81d1 100644 --- a/docs/processors.md +++ b/docs/processors.md @@ -11,6 +11,8 @@ The approach below works in ESLint 9. For ESLint 7, please see our [`check-examp The approach requires that we first indicate the JavaScript files that will be checked for `@example` tags. ```js +import getJsdocProcessorPlugin from 'eslint-plugin-jsdoc/getJsdocProcessorPlugin.js'; + export default [ { files: ['**/*.js'], diff --git a/package.json b/package.json index 3efe1de5d..bf3105c0c 100644 --- a/package.json +++ b/package.json @@ -91,9 +91,16 @@ "main": "./dist/index.cjs", "types": "./dist/index.d.ts", "exports": { - "types": "./dist/index.d.ts", - "import": "./src/index.js", - "require": "./dist/index.cjs" + ".": { + "types": "./dist/index.d.ts", + "import": "./src/index.js", + "require": "./dist/index.cjs" + }, + "./getJsdocProcessorPlugin.js": { + "types": "./dist/getJsdocProcessorPlugin.d.ts", + "import": "./dist/getJsdocProcessorPlugin.cjs", + "require": "./src/getJsdocProcessorPlugin.js" + } }, "name": "eslint-plugin-jsdoc", "mocha": { diff --git a/src/index.js b/src/index.js index ce643d4fa..a8343b94c 100644 --- a/src/index.js +++ b/src/index.js @@ -380,6 +380,4 @@ index.configs['examples-and-default-expressions'] = /** @type {import('eslint'). }) ]); -export { getJsdocProcessorPlugin }; - export default index;