@express-zod-api/migration 25.1.0 → 25.2.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.
package/dist/index.d.ts CHANGED
@@ -1,10 +1,9 @@
1
1
  import { ESLintUtils } from "@typescript-eslint/utils";
2
2
 
3
3
  //#region index.d.ts
4
+ declare const theRule: ESLintUtils.RuleModule<"change" | "add" | "move" | "remove", [], unknown, ESLintUtils.RuleListener>;
4
5
  declare const _default: {
5
- rules: {
6
- v25: ESLintUtils.RuleModule<"change" | "add" | "move" | "remove", [], unknown, ESLintUtils.RuleListener>;
7
- };
6
+ rules: Record<`v${number}`, typeof theRule>;
8
7
  };
9
8
  //#endregion
10
9
  export { _default as default };
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- import{AST_NODE_TYPES as e,ESLintUtils as t}from"@typescript-eslint/utils";const n={zod:`${e.ImportDeclaration}[source.value='zod/v4']`,dateInOutExample:`${e.CallExpression}[callee.object.name='ez'][callee.property.name=/date(In|Out)/] >${e.ObjectExpression} > ${e.Property}[key.name='example']`,getExamples:`${e.CallExpression}[callee.name='getExamples']`},r=e=>Object.keys(e).reduce((t,r)=>Object.assign(t,{[n[r]]:e[r]}),{}),i=t.RuleCreator.withoutDocs({meta:{type:`problem`,fixable:`code`,schema:[],messages:{change:`change {{ subject }} from {{ from }} to {{ to }}`,add:`add {{ subject }} to {{ to }}`,move:`move {{ subject }} to {{ to }}`,remove:`remove {{ subject }}`}},defaultOptions:[],create:e=>r({zod:t=>e.report({node:t.source,messageId:`change`,data:{subject:`import`,from:`zod/v4`,to:`zod`},fix:e=>e.replaceText(t.source,`"zod"`)}),dateInOutExample:t=>e.report({node:t,messageId:`change`,data:{subject:`property`,from:`example`,to:`examples`},fix:n=>n.replaceText(t,`examples: [${e.sourceCode.getText(t.value)}]`)}),getExamples:t=>e.report({node:t,messageId:`change`,data:{subject:`method`,from:`getExamples()`,to:`.meta()?.examples || []`},fix:n=>n.replaceText(t,`(${e.sourceCode.getText(t.arguments[0])}.meta()?.examples || [])`)})})});var a={rules:{v25:i}};export{a as default};
1
+ import{AST_NODE_TYPES as e,ESLintUtils as t}from"@typescript-eslint/utils";const n={zod:`${e.ImportDeclaration}[source.value='zod/v4']`,dateInOutExample:`${e.CallExpression}[callee.object.name='ez'][callee.property.name=/date(In|Out)/] >${e.ObjectExpression} > ${e.Property}[key.name='example']`,getExamples:`${e.CallExpression}[callee.name='getExamples']`},r=e=>Object.keys(e).reduce((t,r)=>Object.assign(t,{[n[r]]:e[r]}),{}),i=`v${`25.2.0`?.split(`.`)[0]??`0`}`,a=t.RuleCreator.withoutDocs({meta:{type:`problem`,fixable:`code`,schema:[],messages:{change:`change {{ subject }} from {{ from }} to {{ to }}`,add:`add {{ subject }} to {{ to }}`,move:`move {{ subject }} to {{ to }}`,remove:`remove {{ subject }}`}},defaultOptions:[],create:e=>r({zod:t=>e.report({node:t.source,messageId:`change`,data:{subject:`import`,from:`zod/v4`,to:`zod`},fix:e=>e.replaceText(t.source,`"zod"`)}),dateInOutExample:t=>e.report({node:t,messageId:`change`,data:{subject:`property`,from:`example`,to:`examples`},fix:n=>n.replaceText(t,`examples: [${e.sourceCode.getText(t.value)}]`)}),getExamples:t=>e.report({node:t,messageId:`change`,data:{subject:`method`,from:`getExamples()`,to:`.meta()?.examples || []`},fix:n=>n.replaceText(t,`(${e.sourceCode.getText(t.arguments[0])}.meta()?.examples || [])`)})})});var o={rules:{[i]:a}};export{o as default};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@express-zod-api/migration",
3
- "version": "25.1.0",
3
+ "version": "25.2.0",
4
4
  "license": "MIT",
5
5
  "description": "Migration scripts for express-zod-api",
6
6
  "repository": {
@@ -28,15 +28,18 @@
28
28
  "dist",
29
29
  "*.md"
30
30
  ],
31
+ "engines": {
32
+ "node": "^20.19.0 || ^22.12.0 || ^24.0.0"
33
+ },
31
34
  "peerDependencies": {
32
35
  "eslint": "^9.0.0",
33
36
  "typescript-eslint": "^8.0.0"
34
37
  },
35
38
  "devDependencies": {
36
- "@typescript-eslint/rule-tester": "^8.35.1"
39
+ "@typescript-eslint/rule-tester": "^8.46.1"
37
40
  },
38
41
  "scripts": {
39
- "pretest": "tsc --noEmit",
42
+ "pretest": "tsc",
40
43
  "test": "vitest run --globals",
41
44
  "build": "tsdown"
42
45
  }