@lntvow/eslint-plugin 10.1.8 → 10.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,6 @@
1
+ import { ESLint } from "eslint";
2
+
3
+ //#region src/index.d.ts
4
+ declare const plugin: ESLint.Plugin;
5
+ //#endregion
6
+ export { plugin as default };
package/dist/index.mjs CHANGED
@@ -1,2 +1,2 @@
1
- var s="@lntvow/eslint-plugin",o="10.1.8";var r={meta:{type:"layout",docs:{description:"Enforce newline before specified keywords",category:"Stylistic Issues",recommended:!0,url:"https://eslint.org/docs/rules/newline-before"},fixable:"whitespace",schema:[]},create(i){let{sourceCode:l}=i;function c(e){let t=l.getTokenBefore(e);t&&(t.type==="Punctuator"&&t.value==="{"||t&&t.loc.end.line===e.loc.start.line-1&&i.report({node:e,message:"Expected at least one empty line before function call.",fix(p){return p.insertTextBefore(e,`
2
- `)}}))}return{CallExpression(e){if(e.callee.type==="Identifier"){let t=e.callee.name;(t==="test"||t==="describe")&&c(e)}}}}};var d={meta:{name:s,version:o},rules:{"newline-before-specified-function-call":r},configs:{}},w=d;export{w as default};
1
+ const e={meta:{name:`@lntvow/eslint-plugin`,version:`10.3.0`},rules:{"newline-before-specified-function-call":{meta:{type:`layout`,docs:{description:`Enforce newline before specified keywords`,recommended:!0,url:`https://eslint.org/docs/rules/newline-before`},fixable:`whitespace`,schema:[]},create(e){let{sourceCode:t}=e;function n(n){let r=t.getTokenBefore(n);r&&(r.type===`Punctuator`&&r.value===`{`||r&&r.loc.end.line===n.loc.start.line-1&&e.report({node:n,message:`Expected at least one empty line before function call.`,fix(e){return e.insertTextBefore(n,`
2
+ `)}}))}return{CallExpression(e){if(e.callee.type===`Identifier`){let t=e.callee.name;(t===`test`||t===`describe`)&&n(e)}}}}}},configs:{}};export{e as default};
package/package.json CHANGED
@@ -1,42 +1,47 @@
1
1
  {
2
2
  "name": "@lntvow/eslint-plugin",
3
- "version": "10.1.8",
4
- "type": "module",
3
+ "version": "10.3.0",
5
4
  "description": "Custom ESLint plugin with additional rules",
6
5
  "keywords": [
7
6
  "eslint-plugin"
8
7
  ],
9
- "license": "MIT",
10
- "author": "lntvow",
8
+ "homepage": "https://github.com/lntvow/eslint-config/tree/main/packages/eslint-plugin",
11
9
  "repository": {
12
10
  "type": "git",
13
- "url": "https://github.com/lntvow/eslint-config.git",
11
+ "url": "git+https://github.com/lntvow/eslint-config.git",
14
12
  "directory": "packages/eslint-plugin"
15
13
  },
16
- "homepage": "https://github.com/lntvow/eslint-config/tree/main/packages/eslint-plugin",
17
- "files": [
18
- "dist"
19
- ],
20
- "types": "./dist/index.d.ts",
21
- "main": "./dist/index.cjs",
22
- "module": "./dist/index.mjs",
14
+ "license": "MIT",
15
+ "author": "lntvow",
16
+ "sideEffects": false,
17
+ "type": "module",
23
18
  "exports": {
24
19
  ".": {
25
- "types": "./dist/index.d.ts",
20
+ "types": "./dist/index.d.mts",
26
21
  "import": "./dist/index.mjs",
27
- "require": "./dist/index.cjs"
22
+ "require": "./dist/index.mjs"
28
23
  }
29
24
  },
25
+ "main": "./dist/index.mjs",
26
+ "module": "./dist/index.mjs",
27
+ "types": "./dist/index.d.mts",
28
+ "files": [
29
+ "dist"
30
+ ],
31
+ "devDependencies": {
32
+ "mocha": "^11.7.1"
33
+ },
30
34
  "peerDependencies": {
31
35
  "eslint": ">=9.0.0"
32
36
  },
33
- "devDependencies": {
34
- "mocha": "^11.7.1"
37
+ "engines": {
38
+ "node": ">=20.19.0"
35
39
  },
36
40
  "scripts": {
37
- "dev": "tsup",
38
- "build": "tsup",
39
- "rimraf": "rimraf ./node_modules/",
41
+ "dev": "tsdown",
42
+ "build": "tsdown",
43
+ "clean": "cli clean ./node_modules/",
44
+ "tidy": "cli tidy",
40
45
  "test": "mocha --import=tsx --watch"
41
46
  }
42
47
  }
package/dist/index.cjs DELETED
@@ -1,2 +0,0 @@
1
- "use strict";var o=Object.defineProperty;var u=Object.getOwnPropertyDescriptor;var d=Object.getOwnPropertyNames;var f=Object.prototype.hasOwnProperty;var m=(n,t)=>{for(var s in t)o(n,s,{get:t[s],enumerable:!0})},g=(n,t,s,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let e of d(t))!f.call(n,e)&&e!==s&&o(n,e,{get:()=>t[e],enumerable:!(i=u(t,e))||i.enumerable});return n};var y=n=>g(o({},"__esModule",{value:!0}),n);var b={};m(b,{default:()=>h});module.exports=y(b);var l="@lntvow/eslint-plugin",c="10.1.8";var p={meta:{type:"layout",docs:{description:"Enforce newline before specified keywords",category:"Stylistic Issues",recommended:!0,url:"https://eslint.org/docs/rules/newline-before"},fixable:"whitespace",schema:[]},create(n){let{sourceCode:t}=n;function s(i){let e=t.getTokenBefore(i);e&&(e.type==="Punctuator"&&e.value==="{"||e&&e.loc.end.line===i.loc.start.line-1&&n.report({node:i,message:"Expected at least one empty line before function call.",fix(a){return a.insertTextBefore(i,`
2
- `)}}))}return{CallExpression(i){if(i.callee.type==="Identifier"){let e=i.callee.name;(e==="test"||e==="describe")&&s(i)}}}}};var w={meta:{name:l,version:c},rules:{"newline-before-specified-function-call":p},configs:{}},h=w;
package/dist/index.d.ts DELETED
@@ -1,5 +0,0 @@
1
- import { ESLint } from 'eslint';
2
-
3
- declare const plugin: ESLint.Plugin;
4
-
5
- export { plugin as default };