eslint-plugin-react-hooks-docs
Advanced tools
Comparing version
@@ -1,3 +0,3 @@ | ||
export declare const rules: { | ||
[filename: string]: any; | ||
declare var rules: { | ||
docs: any; | ||
}; |
'use strict'; | ||
var __importDefault = (this && this.__importDefault) || function (mod) { | ||
return (mod && mod.__esModule) ? mod : { "default": mod }; | ||
var rules = { | ||
docs: require('./rules/docs'), | ||
}; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.rules = void 0; | ||
var requireindex_1 = __importDefault(require("requireindex")); | ||
exports.rules = (0, requireindex_1.default)("".concat(__dirname, "/rules")); | ||
module.exports = { | ||
rules: rules, | ||
configs: { | ||
recommended: { | ||
plugins: ['react-hooks-docs'], | ||
parserOptions: { | ||
ecmaFeatures: { | ||
jsx: true, | ||
}, | ||
}, | ||
rules: { | ||
'react-hooks-docs/docs': 2, | ||
}, | ||
}, | ||
}, | ||
}; |
@@ -16,3 +16,3 @@ 'use strict'; | ||
description: 'Lints react hooks documentation', | ||
url: 'https://github.com/a-tokyo/stylelint-rem-over-px', | ||
url: 'https://github.com/a-tokyo/eslint-plugin-react-hooks-docs', | ||
recommended: true, | ||
@@ -19,0 +19,0 @@ }, |
@@ -1,2 +0,2 @@ | ||
export declare type Node = { | ||
export type Node = { | ||
type: 'Identifier' | 'FunctionDeclaration' | 'VariableDeclaration' | 'ExportNamedDeclaration' | 'ExportDefaultDeclaration' | 'ExpressionStatement' | 'VariableDeclaration' | 'CallExpression' | 'VariableDeclarator' | 'MemberExpression'; | ||
@@ -20,10 +20,10 @@ name: string; | ||
}; | ||
export declare type Program = { | ||
export type Program = { | ||
body: Node[]; | ||
}; | ||
export declare type Options = { | ||
export type Options = { | ||
skipDeclarations: boolean; | ||
skipHooks: string[]; | ||
}; | ||
export declare type Context = { | ||
export type Context = { | ||
report(node: Node, message: string): void; | ||
@@ -30,0 +30,0 @@ options: Options[]; |
{ | ||
"name": "eslint-plugin-react-hooks-docs", | ||
"version": "0.0.2", | ||
"version": "0.0.3", | ||
"description": "Eslint plugin to enforce react hooks documentation", | ||
"main": "dist/index.js", | ||
"repository": { | ||
@@ -18,2 +17,6 @@ "type": "git", | ||
}, | ||
"main": "dist/index.js", | ||
"files": [ | ||
"dist" | ||
], | ||
"scripts": { | ||
@@ -29,15 +32,12 @@ "prepare": "husky install", | ||
}, | ||
"dependencies": { | ||
"requireindex": "~1.2.0" | ||
}, | ||
"devDependencies": { | ||
"@commitlint/cli": "^16.1.0", | ||
"@commitlint/config-conventional": "^16.0.0", | ||
"@types/chai": "^4.3.0", | ||
"@types/eslint": "^8.4.1", | ||
"@types/mocha": "^9.1.0", | ||
"@types/node": "^17.0.17", | ||
"@types/react": "^17.0.39", | ||
"@types/requireindex": "^1.2.0", | ||
"@typescript-eslint/eslint-plugin": "^5.11.0", | ||
"@types/chai": "^4.3.11", | ||
"@types/eslint": "^8.56.2", | ||
"@types/mocha": "^10.0.6", | ||
"@types/node": "^20.11.5", | ||
"@types/react": "^18.2.48", | ||
"@types/requireindex": "^1.2.4", | ||
"@typescript-eslint/eslint-plugin": "^6.19.0", | ||
"eslint": "^8.9.0", | ||
@@ -53,3 +53,3 @@ "eslint-config-airbnb-base": "^15.0.0", | ||
"tsconfig-paths": "^3.12.0", | ||
"typescript": "^4.5.5" | ||
"typescript": "^5.3.3" | ||
}, | ||
@@ -56,0 +56,0 @@ "engines": { |
0
-100%180
4.65%12453
-8.87%9
-18.18%- Removed
- Removed