eslint-config-gorgon 2.0.7 → 2.0.8

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.
Files changed (2) hide show
  1. package/dist/index.js +1 -1
  2. package/package.json +7 -2
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- import w from"eslint-plugin-perfectionist";var n=[w.configs["recommended-natural"],{rules:{"no-console":"warn","no-unused-vars":"warn","perfectionist/sort-enums":"warn"}}];import C from"eslint-plugin-jsx-a11y";var r=[C.flatConfigs.recommended];import S from"eslint-config-prettier";import T from"eslint-plugin-prettier/recommended";var a=[T,S];import l from"eslint-plugin-react";import j from"eslint-plugin-react-hooks";var k=[j.configs["recommended-latest"],l.configs.flat.recommended,{...l.configs.flat["jsx-runtime"],files:["**/*.ts","**/*.tsx","**/*.jsx","**/*.js"],settings:{react:{version:"detect"}}}],p=k;import P from"eslint-plugin-tailwindcss";var c=[...P.configs["flat/recommended"]];import R from"typescript-eslint";var f=[...R.configs.recommended,{rules:{"@typescript-eslint/no-explicit-any":"warn"}}];import m from"fs";import b from"path";var F=()=>{let t=b.join(process.cwd(),"package.json");if(m.existsSync(t)){let e=JSON.parse(m.readFileSync(t,"utf-8")),i=e.dependencies||{},o=e.devDependencies||{};return"react"in i||"react"in o}return!1},d=F;import L from"fs";import H from"path";var I=()=>["tailwind.config.js","tailwind.config.cjs","tailwind.config.mjs","tailwind.config.ts","tailwind.config.mts"].some(i=>L.existsSync(H.join(process.cwd(),i))),u=I;import E from"fs";import v from"path";var J=v.join(process.cwd(),"tsconfig.json"),A=()=>E.existsSync(J),g=A;var s=d(),y=u(),x=g();var h=[...n],D=t=>{let e=h;if((t?.react??s)&&e.push(...p),(t?.a11y??s)&&e.push(...r),(t?.tailwind??y)&&e.push(...c),(t?.prettier??s)&&e.push(...a),t?.typescript??x){let i=["**/node_modules/**","dist/**","output/**"];e=[...h,...f].map(o=>({...o,files:["**/*.ts","**/*.tsx",...o?.files?.flat(1/0)??[]],ignores:[...i,...t?.ignores??[]]}))}return e},Ct=D();export{Ct as default,D as init};
1
+ import C from"eslint-plugin-perfectionist";var r=[C.configs["recommended-natural"],{rules:{"no-console":"warn","no-unused-vars":"warn","perfectionist/sort-enums":"warn"}}];import S from"eslint-plugin-jsx-a11y";var a=[S.flatConfigs.recommended];import T from"eslint-config-prettier";import j from"eslint-plugin-prettier/recommended";var p=[j,T];import m from"eslint-plugin-react";import b from"eslint-plugin-react-hooks";var k=[m.configs.flat.recommended,b.configs["recommended-latest"],{...m.configs.flat["jsx-runtime"],files:["**/*.ts","**/*.tsx","**/*.jsx","**/*.js"],settings:{react:{version:"detect"}}}],c=k;import P from"eslint-plugin-tailwindcss";var f=[...P.configs["flat/recommended"]];import R from"typescript-eslint";var l=[...R.configs.recommended,{rules:{"@typescript-eslint/no-explicit-any":"warn"}}];import d from"fs";import L from"path";var F=()=>{let t=L.join(process.cwd(),"package.json");if(d.existsSync(t)){let e=JSON.parse(d.readFileSync(t,"utf-8")),i=e.dependencies||{},n=e.devDependencies||{};return"react"in i||"react"in n}return!1},u=F;import H from"fs";import I from"path";var E=()=>["tailwind.config.js","tailwind.config.cjs","tailwind.config.mjs","tailwind.config.ts","tailwind.config.mts"].some(i=>H.existsSync(I.join(process.cwd(),i))),g=E;import v from"fs";import J from"path";var A=J.join(process.cwd(),"tsconfig.json"),D=()=>v.existsSync(A),y=D;var s=u(),x=g(),h=y();var w=[...r],o=(t,e)=>t===void 0?e:t,N=t=>{let e=w;if(o(t?.react,s)&&e.push(...c),o(t?.a11y,s)&&e.push(...a),o(t?.tailwind,x)&&e.push(...f),o(t?.prettier,s)&&e.push(...p),o(t?.typescript,h)){let i=["**/node_modules/**","dist/**","output/**"];e=[...w,...l].map(n=>({...n,files:["**/*.ts","**/*.tsx",...n?.files?.flat(1/0)??[]],ignores:[...i,...t?.ignores??[]]}))}return e},St=N();export{St as default,N as init};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-config-gorgon",
3
- "version": "2.0.7",
3
+ "version": "2.0.8",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "license": "MIT",
@@ -27,12 +27,16 @@
27
27
  },
28
28
  "devDependencies": {
29
29
  "@eslint/js": "^9.9.1",
30
+ "@jest/types": "^29.6.3",
30
31
  "@types/eslint-config-prettier": "^6.11.3",
31
32
  "@types/eslint-plugin-jsx-a11y": "^6.9.0",
32
33
  "@types/eslint-plugin-tailwindcss": "^3.17.0",
33
34
  "@types/eslint__js": "^8.42.3",
35
+ "@types/jest": "^29.4.1",
34
36
  "@types/node": "^22.5.2",
35
37
  "eslint": "^9.9.1",
38
+ "jest": "^29.5.0",
39
+ "ts-jest": "^29.0.5",
36
40
  "tsup": "^8.2.4",
37
41
  "typescript": "^5.5.4"
38
42
  },
@@ -40,6 +44,7 @@
40
44
  "lint": "npx eslint",
41
45
  "build": "tsup",
42
46
  "build:watch": "tsup --watch",
43
- "dev": "npm run build && npm run lint"
47
+ "dev": "npm run build && npm run lint",
48
+ "test": "jest"
44
49
  }
45
50
  }