@peerigon/configs 14.0.0 → 14.0.2

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.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,15 @@
1
+ ## [14.0.2](https://github.com/peerigon/configs/compare/v14.0.1...v14.0.2) (2026-02-10)
2
+
3
+ ### Bug Fixes
4
+
5
+ - Improve jsr score ([a616300](https://github.com/peerigon/configs/commit/a616300b3fe4c489232ebd81944f7b6089143fc6))
6
+
7
+ ## [14.0.1](https://github.com/peerigon/configs/compare/v14.0.0...v14.0.1) (2026-02-10)
8
+
9
+ ### Bug Fixes
10
+
11
+ - jsr publish ([08b7a7b](https://github.com/peerigon/configs/commit/08b7a7bdec9a55a76bb6504910b094235e6782bc))
12
+
1
13
  # [14.0.0](https://github.com/peerigon/configs/compare/v13.0.0...v14.0.0) (2026-02-09)
2
14
 
3
15
  ### chore
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./javascript-browser.d.ts"
1
2
  import eslintConfigPrettier from "eslint-config-prettier";
2
3
  import { base } from "../rules/base.js";
3
4
  import { browser } from "../rules/browser.js";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./javascript-node.d.ts"
1
2
  import eslintConfigPrettier from "eslint-config-prettier";
2
3
  import { base } from "../rules/base.js";
3
4
  import { javascript } from "../rules/javascript.js";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./javascript.d.ts"
1
2
  import eslintConfigPrettier from "eslint-config-prettier";
2
3
  import { base } from "../rules/base.js";
3
4
  import { javascript } from "../rules/javascript.js";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./typescript-node.d.ts"
1
2
  import eslintConfigPrettier from "eslint-config-prettier";
2
3
  import { base } from "../rules/base.js";
3
4
  import { javascript } from "../rules/javascript.js";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./typescript-react.d.ts"
1
2
  import eslintConfigPrettier from "eslint-config-prettier";
2
3
  import { base } from "../rules/base.js";
3
4
  import { browser } from "../rules/browser.js";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./typescript.d.ts"
1
2
  import eslintConfigPrettier from "eslint-config-prettier";
2
3
  import { base } from "../rules/base.js";
3
4
  import { javascript } from "../rules/javascript.js";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./base.d.ts"
1
2
  import fs from "node:fs";
2
3
  import path from "node:path";
3
4
  import { includeIgnoreFile } from "@eslint/compat";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./browser.d.ts"
1
2
  import globals from "globals";
2
3
  /** @type {import("eslint").Linter.Config[]} */
3
4
  export const browser = [
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./javascript.d.ts"
1
2
  import js from "@eslint/js";
2
3
  import noOnlyTests from "eslint-plugin-no-only-tests";
3
4
  import unicornPlugin from "eslint-plugin-unicorn";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./node.d.ts"
1
2
  import globals from "globals";
2
3
  /** @type {import("eslint").Linter.Config[]} */
3
4
  export const node = [
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./playwright.d.ts"
1
2
  import pluginPlaywright from "eslint-plugin-playwright";
2
3
  import { globPatterns } from "../lib/glob-patterns.js";
3
4
  const files = globPatterns.tests;
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./react.d.ts"
1
2
  import reactPlugin2 from "@eslint-react/eslint-plugin";
2
3
  import jsxA11yPlugin from "eslint-plugin-jsx-a11y";
3
4
  import reactPlugin from "eslint-plugin-react";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./tanstack-query.d.ts"
1
2
  import pluginQuery from "@tanstack/eslint-plugin-query";
2
3
  import { globPatterns } from "../lib/glob-patterns.js";
3
4
  const files = [
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./typescript.d.ts"
1
2
  import preferArrow from "eslint-plugin-prefer-arrow";
2
3
  import tsEslint from "typescript-eslint";
3
4
  import { globPatterns } from "../lib/glob-patterns.js";
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./vitest.d.ts"
1
2
  import vitestPlugin from "@vitest/eslint-plugin";
2
3
  import { globPatterns } from "../lib/glob-patterns.js";
3
4
  const files = globPatterns.tests;
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./jsx-no-literals.d.ts"
1
2
  import { globPatterns } from "../lib/glob-patterns.js";
2
3
  /** @type {import("eslint").Linter.Config[]} */
3
4
  export const jsxNoLiterals = [
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./no-default-export.d.ts"
1
2
  import { globPatterns } from "../lib/glob-patterns.js";
2
3
  /** @type {import("eslint").Linter.Config[]} */
3
4
  export const noDefaultExport = [
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./no-null.d.ts"
1
2
  /** @type {import("eslint").Linter.Config[]} */
2
3
  export const noNull = [
3
4
  {
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./prefer-array-shorthand.d.ts"
1
2
  /** @type {import("eslint").Linter.Config[]} */
2
3
  export const preferArrayShorthand = [
3
4
  {
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./prefer-interface.d.ts"
1
2
  /** @type {import("eslint").Linter.Config[]} */
2
3
  export const preferInterface = [
3
4
  {
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./base.d.ts"
1
2
  /**
2
3
  * ## Base config for Prettier.
3
4
  *
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./base.d.ts"
1
2
  /** @type {import("semantic-release").Options} */
2
3
  export const config = {
3
4
  branches: [
@@ -1,3 +1,4 @@
1
+ // @ts-self-types="./cross-publish.d.ts"
1
2
  import { config as baseConfig } from "./base.js";
2
3
  /**
3
4
  * @param {{ github: boolean; jsr: boolean }} options?
@@ -1,54 +1,38 @@
1
1
  {
2
- // Inspired by https://www.totaltypescript.com/tsconfig-cheat-sheet
3
- // and https://2ality.com/2025/01/tsconfig-json.html
4
- "compilerOptions": {
5
- // == Target and module settings ==
6
- // Deliberately not using ESNext/NodeNext here to avoid breaking changes just by updating TypeScript.
7
- "target": "es2024",
8
- "module": "Preserve",
9
- "moduleDetection": "force",
10
- "lib": ["es2024"],
11
- // == Strictness settings ==
12
- "strict": true,
13
- "noImplicitOverride": true,
14
- // Warns about functions with implicit returns where other code paths return a value.
15
- // This option is basically the same as ESLint's `consistent-return` rule.
16
- "noImplicitReturns": true,
17
- "noUncheckedIndexedAccess": true,
18
- "noUncheckedSideEffectImports": true,
19
- "noFallthroughCasesInSwitch": true,
20
- // We decided to turn off `exactOptionalPropertyTypes` because it's too strict
21
- // by complaining about too much unproblematic code. We may revisit this decision later.
22
- "exactOptionalPropertyTypes": false,
23
- "noPropertyAccessFromIndexSignature": true,
24
- // == Module resolution settings ==
25
- "resolveJsonModule": true,
26
- "rewriteRelativeImportExtensions": true,
27
- "allowImportingTsExtensions": true,
28
- // == Other settings ==
29
- "allowJs": true,
30
- "checkJs": true,
31
- "forceConsistentCasingInFileNames": true,
32
- // Using noEmit true here because you should have a separate build config anyway
33
- "noEmit": true,
34
- // Not setting skipLibCheck: true for now because it can hide type conflicts in dependencies.
35
- // You can override this in your app if you can't fix it with your package manager.
36
- // If you want to learn more about the trade-offs,
37
- // see https://www.testim.io/blog/typescript-skiplibcheck/
38
- "skipLibCheck": false,
39
- "verbatimModuleSyntax": true,
40
- // Recommended for new projects.
41
- // Disable this if you already have an existing codebase that uses non-erasable syntax.
42
- "erasableSyntaxOnly": true
43
- },
44
- "exclude": [
45
- "${configDir}/dist",
46
- "${configDir}/coverage",
47
- "${configDir}/node_modules",
48
- "${configDir}/build",
49
- "${configDir}/.next",
50
- "${configDir}/.nuxt",
51
- "${configDir}/.vercel"
2
+ "compilerOptions": {
3
+ "target": "es2024",
4
+ "module": "Preserve",
5
+ "moduleDetection": "force",
6
+ "lib": [
7
+ "es2024"
52
8
  ],
53
- "$schema": "https://json.schemastore.org/tsconfig"
9
+ "strict": true,
10
+ "noImplicitOverride": true,
11
+ "noImplicitReturns": true,
12
+ "noUncheckedIndexedAccess": true,
13
+ "noUncheckedSideEffectImports": true,
14
+ "noFallthroughCasesInSwitch": true,
15
+ "exactOptionalPropertyTypes": false,
16
+ "noPropertyAccessFromIndexSignature": true,
17
+ "resolveJsonModule": true,
18
+ "rewriteRelativeImportExtensions": true,
19
+ "allowImportingTsExtensions": true,
20
+ "allowJs": true,
21
+ "checkJs": true,
22
+ "forceConsistentCasingInFileNames": true,
23
+ "noEmit": true,
24
+ "skipLibCheck": false,
25
+ "verbatimModuleSyntax": true,
26
+ "erasableSyntaxOnly": true
27
+ },
28
+ "exclude": [
29
+ "${configDir}/dist",
30
+ "${configDir}/coverage",
31
+ "${configDir}/node_modules",
32
+ "${configDir}/build",
33
+ "${configDir}/.next",
34
+ "${configDir}/.nuxt",
35
+ "${configDir}/.vercel"
36
+ ],
37
+ "$schema": "https://json.schemastore.org/tsconfig"
54
38
  }
@@ -1,10 +1,12 @@
1
1
  {
2
- "compilerOptions": {
3
- "target": "es2022",
4
- "lib": ["es2022"],
5
- "declaration": true,
6
- "noEmit": false,
7
- "outDir": "${configDir}/dist"
8
- },
9
- "$schema": "https://json.schemastore.org/tsconfig"
2
+ "compilerOptions": {
3
+ "target": "es2022",
4
+ "lib": [
5
+ "es2022"
6
+ ],
7
+ "declaration": true,
8
+ "noEmit": false,
9
+ "outDir": "${configDir}/dist"
10
+ },
11
+ "$schema": "https://json.schemastore.org/tsconfig"
10
12
  }
@@ -1,14 +1,15 @@
1
1
  {
2
- "compilerOptions": {
3
- "target": "es2022",
4
- "lib": ["es2022"],
5
- "declaration": true,
6
- "declarationMap": true,
7
- "noEmit": false,
8
- "outDir": "${configDir}/dist",
9
- "sourceMap": true,
10
- // Use inlineSources: true because often we only publish the dist folder on npm
11
- "inlineSources": true
12
- },
13
- "$schema": "https://json.schemastore.org/tsconfig"
2
+ "compilerOptions": {
3
+ "target": "es2022",
4
+ "lib": [
5
+ "es2022"
6
+ ],
7
+ "declaration": true,
8
+ "declarationMap": true,
9
+ "noEmit": false,
10
+ "outDir": "${configDir}/dist",
11
+ "sourceMap": true,
12
+ "inlineSources": true
13
+ },
14
+ "$schema": "https://json.schemastore.org/tsconfig"
14
15
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@peerigon/configs",
3
- "version": "14.0.0",
3
+ "version": "14.0.2",
4
4
  "description": "Configs for ESLint, Prettier, TypeScript & friends",
5
5
  "keywords": [
6
6
  "eslint",
@@ -55,8 +55,17 @@
55
55
  "README.md"
56
56
  ],
57
57
  "scripts": {
58
+ "build": "run-s build:*",
59
+ "build:clear": "rimraf dist",
60
+ "build:tsc": "tsc",
61
+ "build:jsr-typescript-configs": "node tools/prepare-jsr-publish-assets.js",
62
+ "prepare": "husky",
63
+ "prepublishOnly": "npm run build",
64
+ "release": "semantic-release",
58
65
  "test": "run-p test:*",
59
66
  "test:exports": "node package.json.test.js",
67
+ "test:format": "prettier --check .",
68
+ "test:lint": "eslint --max-warnings 0 .",
60
69
  "test:presets:javascript": "cd eslint/presets/javascript.test; eslint --max-warnings 0 .",
61
70
  "test:presets:typescript": "cd eslint/presets/typescript.test; eslint --max-warnings 0 .",
62
71
  "test:presets:typescript-react": "cd eslint/presets/typescript-react.test; eslint --max-warnings 0 .",
@@ -66,15 +75,7 @@
66
75
  "test:styles:no-null": "cd eslint/styles/no-null.test; eslint --max-warnings 0 .",
67
76
  "test:styles:prefer-array-shorthand": "cd eslint/styles/prefer-array-shorthand.test; eslint --max-warnings 0 .",
68
77
  "test:styles:prefer-interface": "cd eslint/styles/prefer-interface.test; eslint --max-warnings 0 .",
69
- "test:lint": "eslint --max-warnings 0 .",
70
- "test:types": "tsc --noEmit",
71
- "test:format": "prettier --check .",
72
- "build": "run-s build:*",
73
- "build:clear": "rimraf dist",
74
- "build:tsc": "tsc",
75
- "prepublishOnly": "npm run build",
76
- "prepare": "husky",
77
- "release": "semantic-release"
78
+ "test:types": "tsc --noEmit"
78
79
  },
79
80
  "dependencies": {
80
81
  "@eslint-react/eslint-plugin": "^2.12.2",