@yunarch/config-web
Version:
Shared configurations for web projects.
1 lines • 20.2 kB
JSON
{"plugins":["import","jsdoc","unicorn"],"categories":{"correctness":"off"},"env":{"builtin":true,"browser":true,"es2024":true,"node":true},"globals":{"suite":"writable","test":"writable","describe":"writable","it":"writable","expectTypeOf":"writable","assertType":"writable","expect":"writable","assert":"writable","chai":"writable","vitest":"writable","vi":"writable","beforeAll":"writable","afterAll":"writable","beforeEach":"writable","afterEach":"writable","onTestFailed":"writable","onTestFinished":"writable"},"settings":{"jsdoc":{"structuredTags":{"next":{"required":["type"]},"rejects":{"required":["type"]}}},"vitest":{"typecheck":true}},"ignorePatterns":["**/node_modules","**/.pnp","**/.pnp.js","**/coverage","**/.nyc_output","**/.DS_Store","**/*.pem","**/npm-debug.*","**/npm-debug.log*","**/yarn-debug.log*","**/yarn-error.log*","**/.pnpm-debug.log*","**/logs","**/*.log","**/.turbo","**/.expo/","**/dist/","**/*.jks","**/*.p8","**/*.p12","**/*.key","**/*.mobileprovision","**/*.orig.*","**/web-build/","**/expo-env.d.ts","**/.pnp.*",".yarn/*","!.yarn/cache","!.yarn/patches","!.yarn/plugins","!.yarn/releases","!.yarn/sdks","!.yarn/versions","**/.env*","!**/.env.example","**/.dockerfile.env","**/.env.local","**/.env.development.local","**/.env.test.local","**/.env.production.local","**/.envrc.local","**/.eslintcache","**/.eslint-config-inspector","**/pids","**/*.pid","**/*.seed","**/*.pid.lock","**/.vercel","**/.next/","**/out/","**/build","**/.swc","**/*.tsbuildinfo","**/mockServiceWorker.js","src/**/eslint/typegen.d.ts","**/node_modules/","**/output","**/.output","**/build/","**/*.min.*","**/package-lock.json","**/yarn.lock","**/.yarn/","**/.yarnrc.yml","**/.pnp.cjs","**/bun.lock","**/bun.lockb","**/pnpm-lock.yaml","**/.vite-inspect","**/.vitepress/cache","**/vite.config.*.timestamp-*","**/coverage/","**/.nyc_output/","**/__snapshots__","**/.vscode/","**/.idea/","**/.cache","**/.nuxt","**/.next","**/.svelte-kit","**/.changeset","**/.turbo/","**/Thumbs.db","**/temp","**/.temp","**/tmp","**/.tmp","**/.history","**/CHANGELOG*","**/LICENSE*"],"rules":{"constructor-super":"error","for-direction":"error","no-async-promise-executor":"error","no-case-declarations":"error","no-class-assign":"error","no-compare-neg-zero":"error","no-cond-assign":"error","no-const-assign":"error","no-constant-binary-expression":"error","no-constant-condition":"error","no-control-regex":"error","no-debugger":"error","no-delete-var":"error","no-dupe-class-members":"error","no-dupe-else-if":"error","no-dupe-keys":"error","no-duplicate-case":"error","no-empty":"error","no-empty-character-class":"error","no-empty-pattern":"error","no-empty-static-block":"error","no-ex-assign":"error","no-extra-boolean-cast":"error","no-fallthrough":"error","no-func-assign":"error","no-global-assign":"error","no-import-assign":"error","no-invalid-regexp":"error","no-irregular-whitespace":"error","no-loss-of-precision":"error","no-misleading-character-class":"error","no-new-native-nonconstructor":"error","no-nonoctal-decimal-escape":"error","no-obj-calls":"error","no-prototype-builtins":"error","no-redeclare":"error","no-regex-spaces":"error","no-self-assign":"error","no-setter-return":"error","no-shadow-restricted-names":"error","no-sparse-arrays":"error","no-this-before-super":"error","no-unassigned-vars":"error","no-unsafe-finally":"error","no-unsafe-negation":"error","no-unsafe-optional-chaining":"error","no-unused-labels":"error","no-unused-private-class-members":"error","no-unused-vars":["error",{"args":"none","caughtErrors":"none","ignoreRestSiblings":true,"vars":"all"}],"no-useless-backreference":"error","no-useless-catch":"error","no-useless-escape":"error","no-with":"error","preserve-caught-error":"error","require-yield":"error","use-isnan":"error","valid-typeof":"error","array-callback-return":["error",{"allowImplicit":true}],"block-scoped-var":"error","default-case-last":"error","eqeqeq":"error","func-names":["error","as-needed"],"grouped-accessor-pairs":"error","max-lines":["warn",300],"max-params":["warn",4],"new-cap":["error",{"capIsNew":false}],"no-alert":"error","no-array-constructor":"error","no-bitwise":"error","no-caller":"error","no-console":"error","no-constructor-return":"error","no-else-return":"warn","no-eval":"error","no-extend-native":"error","no-extra-bind":"error","no-extra-label":"error","no-implicit-coercion":["error",{"allow":["!!","+"]}],"no-iterator":"error","no-label-var":"error","no-labels":"error","no-lone-blocks":"error","no-lonely-if":"warn","no-multi-assign":"error","no-new":"error","no-new-func":"error","no-new-wrappers":"error","no-param-reassign":"error","no-promise-executor-return":"error","no-proto":"error","no-return-assign":"error","no-script-url":"error","no-self-compare":"error","no-sequences":"error","no-template-curly-in-string":"error","no-unneeded-ternary":"error","no-unused-expressions":"error","no-useless-call":"error","no-useless-computed-key":"warn","no-useless-concat":"error","no-useless-rename":"warn","no-useless-return":"warn","no-var":"error","no-void":["error",{"allowAsStatement":true}],"object-shorthand":"warn","prefer-const":"warn","prefer-numeric-literals":"error","prefer-object-has-own":"error","prefer-object-spread":"warn","prefer-promise-reject-errors":["error",{"allowEmptyReject":true}],"prefer-rest-params":"error","prefer-spread":"error","prefer-template":"warn","symbol-description":"error","yoda":"warn","import/namespace":"error","import/default":"error","import/no-named-as-default":"warn","import/no-named-as-default-member":"warn","import/no-duplicates":["error",{"prefer-inline":true}],"import/first":"error","import/no-absolute-path":"error","import/no-amd":"error","import/no-cycle":["error",{"ignoreExternal":false,"maxDepth":3}],"import/no-dynamic-require":"error","import/no-mutable-exports":"error","import/no-self-import":"error","jsdoc/check-access":"error","jsdoc/check-property-names":"error","jsdoc/check-tag-names":"error","jsdoc/empty-tags":"error","jsdoc/implements-on-classes":"error","jsdoc/no-defaults":"error","jsdoc/require-param":["error",{"checkDestructured":false,"enableRestElementFixer":false}],"jsdoc/require-param-description":"error","jsdoc/require-param-name":"error","jsdoc/require-param-type":"error","jsdoc/require-property":"error","jsdoc/require-property-description":"error","jsdoc/require-property-name":"error","jsdoc/require-property-type":"error","jsdoc/require-returns":"error","jsdoc/require-returns-description":"error","jsdoc/require-returns-type":"error","jsdoc/require-yields":"error","unicorn/catch-error-name":"error","unicorn/consistent-assert":"error","unicorn/consistent-date-clone":"error","unicorn/consistent-empty-array-spread":"error","unicorn/consistent-existence-index-check":"error","unicorn/consistent-function-scoping":"error","unicorn/consistent-template-literal-escape":"error","unicorn/error-message":"error","unicorn/escape-case":"error","unicorn/explicit-length-check":"error","unicorn/filename-case":["error",{"cases":{"camelCase":true,"kebabCase":true,"pascalCase":true}}],"unicorn/new-for-builtins":"error","unicorn/no-abusive-eslint-disable":"error","unicorn/no-accessor-recursion":"error","unicorn/no-anonymous-default-export":"error","unicorn/no-array-callback-reference":"error","unicorn/no-array-for-each":"error","unicorn/no-array-method-this-argument":"error","unicorn/no-array-reverse":"error","unicorn/no-array-sort":"error","unicorn/no-await-expression-member":"error","unicorn/no-await-in-promise-methods":"error","unicorn/no-console-spaces":"error","unicorn/no-document-cookie":"error","unicorn/no-empty-file":"error","unicorn/no-hex-escape":"error","unicorn/no-immediate-mutation":"error","unicorn/no-instanceof-builtins":"error","unicorn/no-invalid-fetch-options":"error","unicorn/no-invalid-remove-event-listener":"error","unicorn/no-lonely-if":"error","unicorn/no-magic-array-flat-depth":"error","unicorn/no-negated-condition":"error","unicorn/no-negation-in-equality-check":"error","unicorn/no-new-array":"error","unicorn/no-new-buffer":"error","unicorn/no-object-as-default-parameter":"error","unicorn/no-process-exit":"error","unicorn/no-single-promise-in-promise-methods":"error","unicorn/no-static-only-class":"error","unicorn/no-thenable":"error","unicorn/no-this-assignment":"error","unicorn/no-typeof-undefined":"error","unicorn/no-unnecessary-array-flat-depth":"error","unicorn/no-unnecessary-array-splice-count":"error","unicorn/no-unnecessary-await":"error","unicorn/no-unnecessary-slice-end":"error","unicorn/no-unreadable-array-destructuring":"error","unicorn/no-unreadable-iife":"error","unicorn/no-useless-collection-argument":"error","unicorn/no-useless-error-capture-stack-trace":"error","unicorn/no-useless-fallback-in-spread":"error","unicorn/no-useless-length-check":"error","unicorn/no-useless-promise-resolve-reject":"error","unicorn/no-useless-spread":"error","unicorn/no-useless-switch-case":"error","unicorn/no-useless-undefined":["error",{"checkArguments":false}],"unicorn/no-zero-fractions":"error","unicorn/numeric-separators-style":"error","unicorn/prefer-add-event-listener":"error","unicorn/prefer-array-find":"error","unicorn/prefer-array-flat":"error","unicorn/prefer-array-flat-map":"error","unicorn/prefer-array-index-of":"error","unicorn/prefer-array-some":"error","unicorn/prefer-at":"error","unicorn/prefer-bigint-literals":"error","unicorn/prefer-blob-reading-methods":"error","unicorn/prefer-class-fields":"error","unicorn/prefer-classlist-toggle":"error","unicorn/prefer-code-point":"error","unicorn/prefer-date-now":"error","unicorn/prefer-default-parameters":"error","unicorn/prefer-dom-node-append":"error","unicorn/prefer-dom-node-dataset":"error","unicorn/prefer-dom-node-remove":"error","unicorn/prefer-dom-node-text-content":"error","unicorn/prefer-event-target":"error","unicorn/prefer-global-this":"error","unicorn/prefer-includes":"error","unicorn/prefer-keyboard-event-key":"error","unicorn/prefer-logical-operator-over-ternary":"error","unicorn/prefer-math-min-max":"error","unicorn/prefer-math-trunc":"error","unicorn/prefer-modern-dom-apis":"error","unicorn/prefer-modern-math-apis":"error","unicorn/prefer-module":"error","unicorn/prefer-native-coercion-functions":"error","unicorn/prefer-negative-index":"error","unicorn/prefer-node-protocol":"error","unicorn/prefer-number-properties":["error",{"checkInfinity":true,"checkNaN":true}],"unicorn/prefer-object-from-entries":"error","unicorn/prefer-optional-catch-binding":"error","unicorn/prefer-prototype-methods":"error","unicorn/prefer-query-selector":"error","unicorn/prefer-reflect-apply":"error","unicorn/prefer-regexp-test":"error","unicorn/prefer-response-static-json":"error","unicorn/prefer-set-has":"error","unicorn/prefer-set-size":"error","unicorn/prefer-spread":"error","unicorn/prefer-string-raw":"error","unicorn/prefer-string-replace-all":"error","unicorn/prefer-string-slice":"error","unicorn/prefer-string-starts-ends-with":"error","unicorn/prefer-string-trim-start-end":"error","unicorn/prefer-structured-clone":"error","unicorn/prefer-ternary":"error","unicorn/prefer-top-level-await":"warn","unicorn/prefer-type-error":"error","unicorn/relative-url-style":"error","unicorn/require-array-join-separator":"error","unicorn/require-module-attributes":"error","unicorn/require-module-specifiers":"error","unicorn/require-number-to-fixed-digits-argument":"error","unicorn/switch-case-braces":"error","unicorn/switch-case-break-position":"error","unicorn/text-encoding-identifier-case":"error","unicorn/throw-new-error":"error"},"overrides":[{"files":["**/*.{ts,cts,mts}","**/*.{tsx,ctsx,mtsx}"],"rules":{"constructor-super":"off","no-class-assign":"off","no-const-assign":"off","no-dupe-keys":"off","no-func-assign":"off","no-import-assign":"off","no-new-native-nonconstructor":"off","no-obj-calls":"off","no-redeclare":["error",{"builtinGlobals":false}],"no-setter-return":"off","no-this-before-super":"off","no-unsafe-negation":"off","no-with":"off","prefer-const":"error","no-unused-vars":"off","no-useless-constructor":"error","no-empty-function":"error","default-param-last":"error","no-loop-func":"error","no-shadow":"error","no-use-before-define":["error",{"classes":false,"functions":false,"variables":true}],"typescript/ban-ts-comment":["error",{"ts-expect-error":"allow-with-description"}],"typescript/no-duplicate-enum-values":"error","typescript/no-dynamic-delete":"error","typescript/no-empty-object-type":["error",{"allowInterfaces":"always"}],"typescript/no-explicit-any":"error","typescript/no-extra-non-null-assertion":"error","typescript/no-extraneous-class":"error","typescript/no-invalid-void-type":"error","typescript/no-misused-new":"error","typescript/no-namespace":"error","typescript/no-non-null-asserted-nullish-coalescing":"error","typescript/no-non-null-asserted-optional-chain":"error","typescript/no-non-null-assertion":"error","typescript/no-require-imports":"error","typescript/no-this-alias":"error","typescript/no-unnecessary-type-constraint":"error","typescript/no-unsafe-declaration-merging":"error","typescript/no-unsafe-function-type":"error","typescript/no-wrapper-object-types":"error","typescript/prefer-as-const":"error","typescript/prefer-literal-enum-member":"error","typescript/prefer-namespace-keyword":"error","typescript/triple-slash-reference":"error","typescript/unified-signatures":["error",{"ignoreDifferentlyNamedParameters":true,"ignoreOverloadsWithDifferentJSDoc":true}],"typescript/adjacent-overload-signatures":"error","typescript/array-type":"error","typescript/ban-tslint-comment":"error","typescript/class-literal-property-style":"error","typescript/consistent-generic-constructors":"error","typescript/consistent-indexed-object-style":"error","typescript/consistent-type-assertions":"error","typescript/consistent-type-definitions":"off","typescript/no-confusing-non-null-assertion":"error","typescript/no-inferrable-types":"error","typescript/prefer-for-of":"error","typescript/prefer-function-type":"error","typescript/consistent-type-imports":["error",{"disallowTypeAnnotations":false,"fixStyle":"inline-type-imports","prefer":"type-imports"}],"typescript/explicit-function-return-type":"off","typescript/no-import-type-side-effects":"error","typescript/no-useless-empty-export":"warn","typescript/restrict-template-expressions":["error",{"allowNumber":true,"allowBoolean":true}],"no-throw-literal":"off","prefer-promise-reject-errors":"off","require-await":"off","typescript/await-thenable":"error","typescript/no-array-delete":"error","typescript/no-base-to-string":"error","typescript/no-confusing-void-expression":"error","typescript/no-deprecated":"error","typescript/no-duplicate-type-constituents":"error","typescript/no-floating-promises":"error","typescript/no-for-in-array":"error","typescript/no-implied-eval":"error","typescript/no-meaningless-void-operator":"error","typescript/no-misused-promises":["error",{"checksVoidReturn":{"attributes":false}}],"typescript/no-misused-spread":"error","typescript/no-mixed-enums":"error","typescript/no-redundant-type-constituents":"error","typescript/no-unnecessary-boolean-literal-compare":"error","typescript/no-unnecessary-template-expression":"error","typescript/no-unnecessary-type-arguments":"error","typescript/no-unnecessary-type-assertion":"error","typescript/no-unnecessary-type-conversion":"error","typescript/no-unnecessary-type-parameters":"error","typescript/no-unsafe-argument":"error","typescript/no-unsafe-assignment":"error","typescript/no-unsafe-call":"error","typescript/no-unsafe-enum-comparison":"error","typescript/no-unsafe-member-access":"error","typescript/no-unsafe-return":"error","typescript/no-unsafe-unary-minus":"error","typescript/no-useless-default-assignment":"error","typescript/only-throw-error":"error","typescript/prefer-promise-reject-errors":"error","typescript/prefer-reduce-type-parameter":"error","typescript/prefer-return-this-type":"error","typescript/related-getter-setter-pairs":"error","typescript/require-await":"error","typescript/restrict-plus-operands":["error",{"allowAny":false,"allowBoolean":false,"allowNullish":false,"allowNumberAndString":false,"allowRegExp":false}],"typescript/return-await":["error","error-handling-correctness-only"],"typescript/unbound-method":"error","typescript/use-unknown-in-catch-callback-variable":"error","typescript/dot-notation":"error","typescript/non-nullable-type-assertion-style":"error","typescript/prefer-find":"error","typescript/prefer-includes":"error","typescript/prefer-nullish-coalescing":"error","typescript/prefer-regexp-exec":"error","typescript/prefer-string-starts-ends-with":"error","typescript/require-array-sort-compare":["error",{"ignoreStringArrays":true}],"typescript/switch-exhaustiveness-check":"warn","jsdoc/require-param":["error",{"checkDestructured":false,"enableRestElementFixer":false}],"jsdoc/require-param-type":"off","jsdoc/require-property-type":"off","jsdoc/require-returns-type":"off"},"plugins":["typescript"]},{"files":["**/__tests__/**/*.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/*.spec.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/*.test.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/*.bench.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/*.benchmark.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}"],"rules":{"vitest/expect-expect":"error","vitest/no-commented-out-tests":"error","vitest/no-conditional-expect":"error","vitest/no-disabled-tests":"warn","vitest/no-focused-tests":"error","vitest/no-identical-title":"error","vitest/no-import-node-test":"error","vitest/no-interpolation-in-snapshots":"error","vitest/no-mocks-import":"error","vitest/no-standalone-expect":"error","vitest/no-unneeded-async-expect-function":"error","vitest/prefer-called-exactly-once-with":"error","vitest/require-local-test-context-for-concurrent-snapshots":"error","vitest/valid-describe-callback":"error","vitest/valid-expect":"error","vitest/valid-expect-in-promise":"error","vitest/valid-title":"error","vitest/consistent-test-it":["error",{"fn":"it","withinDescribe":"it"}],"vitest/prefer-hooks-in-order":"error","vitest/prefer-lowercase-title":"error"},"plugins":["vitest"]},{"files":["**/*.{ts,cts,mts}","**/*.{tsx,ctsx,mtsx}"],"rules":{"typescript/only-throw-error":["error",{"allow":["Redirect","NotFoundError"]}]},"plugins":["typescript"]},{"files":["**/*.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}"],"rules":{"react/exhaustive-deps":"warn","react/no-array-index-key":"warn","react/no-clone-element":"warn","react/no-direct-mutation-state":"error","react/rules-of-hooks":"error","react/jsx-no-comment-textnodes":"warn","react/jsx-no-useless-fragment":"warn","react/only-export-components":["error",{}]},"plugins":["react"]},{"files":["**/*.{ts,cts,mts}","**/*.{tsx,ctsx,mtsx}"],"rules":{"react/exhaustive-deps":"warn","react/no-array-index-key":"warn","react/no-clone-element":"warn","react/no-direct-mutation-state":"error","react/rules-of-hooks":"error","react/jsx-no-comment-textnodes":"warn","react/jsx-no-useless-fragment":"warn"},"plugins":["react"]},{"files":["**/scripts/**/*.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/tasks/**/*.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/bin/**/*.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/bin.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/*.bin.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/cli/**/*.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/cli.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/*.cli.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}"],"rules":{"no-console":"off","unicorn/no-process-exit":"off","typescript/no-floating-promises":"off"},"plugins":["typescript"]},{"files":["**/*.d.{ts,cts,mts}"],"rules":{"import/no-duplicates":"off","typescript/consistent-indexed-object-style":"off"},"plugins":["typescript"]},{"files":["**/*.config.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}","**/*.config.*.{js,jsx,cjs,cjsx,mjs,mjsx,ts,tsx,cts,ctsx,mts,mtjsx}"],"rules":{"no-console":"off","typescript/explicit-function-return-type":"off"},"plugins":["typescript"]}]}