From 98a6e5ac6d05a49b86081b9b357ac037f3060f70 Mon Sep 17 00:00:00 2001 From: Alexandre Bodin Date: Tue, 10 Sep 2024 17:21:10 +0200 Subject: [PATCH] chore: update readme and some typescript issues --- README.md | 22 ++++++-- package.json | 1 + pnpm-lock.yaml | 135 +++++++++++++++++++++++++------------------------ src/index.ts | 2 +- 4 files changed, 89 insertions(+), 71 deletions(-) diff --git a/README.md b/README.md index 14c125b..7c7abde 100644 --- a/README.md +++ b/README.md @@ -29,9 +29,7 @@ npx @strapi/sdk-plugin@latest init my-plugin That will create a directory with all your plugin project files. -Once your project has been installed, you will have access to the `strapi-plugin` command. - -Run `strapi-plugin -h` for more information on CLI usage. +Once your project has been installed, Multiple commands are available to you. ## Commands @@ -47,19 +45,35 @@ Creates a new plugin at the given path. ### `build` -Builds your current package based on the configuration in your `package.json` and `packup.config.ts` (if applicable). +Builds your current package based on the configuration in your `package.json`. - `--minify` – minifies the output (default `false`). - `--sourcemap` – generates sourcemaps for the output (default `true`). +```sh +yarn run build +``` + ### `watch` Watch & compile your strapi plugin for local development. +```sh +yarn run watch +``` + ### `watch:link` Recompiles your plugin automatically on changes and runs yalc push --publish +```sh +yarn run watch:link +``` + ### `verify` Verifies the output of your plugin before publishing it + +```sh +yarn run verify +``` diff --git a/package.json b/package.json index 5650269..efd14a5 100644 --- a/package.json +++ b/package.json @@ -87,6 +87,7 @@ "@swc/jest": "^0.2.36", "@types/git-url-parse": "9.0.3", "@types/jest": "^29.5.12", + "@types/node": "^22.5.4", "@types/nodemon": "^1.19.6", "@types/prettier": "^2.0.0", "@typescript-eslint/eslint-plugin": "^7.6.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 007da1b..6adfd9f 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -13,7 +13,7 @@ importers: version: 26.0.1(rollup@4.14.1) '@strapi/pack-up': specifier: '>=5.0.1-alpha.1 <6.0.0' - version: 5.0.1-alpha.1(@types/node@20.12.6) + version: 5.0.1-alpha.1(@types/node@22.5.4) '@types/prompts': specifier: 2.4.9 version: 2.4.9 @@ -71,7 +71,7 @@ importers: version: 2.27.1 '@commitlint/cli': specifier: ^19.2.1 - version: 19.2.1(@types/node@20.12.6)(typescript@5.4.4) + version: 19.2.1(@types/node@22.5.4)(typescript@5.4.4) '@commitlint/config-conventional': specifier: ^19.1.0 version: 19.1.0 @@ -90,6 +90,9 @@ importers: '@types/jest': specifier: ^29.5.12 version: 29.5.12 + '@types/node': + specifier: ^22.5.4 + version: 22.5.4 '@types/nodemon': specifier: ^1.19.6 version: 1.19.6 @@ -113,7 +116,7 @@ importers: version: 9.0.11 jest: specifier: ^29.7.0 - version: 29.7.0(@types/node@20.12.6) + version: 29.7.0(@types/node@22.5.4) lint-staged: specifier: ^15.2.2 version: 15.2.2 @@ -1009,8 +1012,8 @@ packages: '@types/node@12.20.55': resolution: {integrity: sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ==} - '@types/node@20.12.6': - resolution: {integrity: sha512-3KurE8taB8GCvZBPngVbp0lk5CKi8M9f9k1rsADh0Evdz5SzJ+Q+Hx9uHoFGsLnLnd1xmkDQr2hVhlA0Mn0lKQ==} + '@types/node@22.5.4': + resolution: {integrity: sha512-FDuKUJQm/ju9fT/SeX/6+gBzoPzlVCzfzmGkwKvRHQVxi4BntVbyIwf6a4Xn62mrvndLiml6z/UBXIdEVjQLXg==} '@types/nodemon@1.19.6': resolution: {integrity: sha512-vjKuaQOLUA5EY2zkUmWG1ipXbKt9Wd+H/0SiIuHVeH4cHtt6509iRUGH9ZR0iqgUrtj3BrP9KqoTuV3ZCbQcYA==} @@ -3911,8 +3914,8 @@ packages: undefsafe@2.0.5: resolution: {integrity: sha512-WxONCrssBM8TSPRqN5EmsjVrsv4A8X12J4ArBiiayv3DyyG3ZlIg6yysuuSYdZsVz3TKcTg2fd//Ujd4CHV1iA==} - undici-types@5.26.5: - resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} + undici-types@6.19.8: + resolution: {integrity: sha512-ve2KP6f/JnbPBFyobGHuerC9g1FYGn/F8n1LWTwNxCEzd6IfqTwUQcNXgEtmmQ6DlRrC1hrSrBnCZPokRrDHjw==} unicorn-magic@0.1.0: resolution: {integrity: sha512-lRfVq8fE8gz6QMBuDM6a+LO3IAzTi05H6gCVaUpir2E1Rwpo4ZUog45KpNXKC/Mn3Yb9UDuHumeFTo9iV/D9FQ==} @@ -4479,11 +4482,11 @@ snapshots: human-id: 1.0.2 prettier: 2.8.8 - '@commitlint/cli@19.2.1(@types/node@20.12.6)(typescript@5.4.4)': + '@commitlint/cli@19.2.1(@types/node@22.5.4)(typescript@5.4.4)': dependencies: '@commitlint/format': 19.0.3 '@commitlint/lint': 19.1.0 - '@commitlint/load': 19.2.0(@types/node@20.12.6)(typescript@5.4.4) + '@commitlint/load': 19.2.0(@types/node@22.5.4)(typescript@5.4.4) '@commitlint/read': 19.2.1 '@commitlint/types': 19.0.3 execa: 8.0.1 @@ -4530,7 +4533,7 @@ snapshots: '@commitlint/rules': 19.0.3 '@commitlint/types': 19.0.3 - '@commitlint/load@19.2.0(@types/node@20.12.6)(typescript@5.4.4)': + '@commitlint/load@19.2.0(@types/node@22.5.4)(typescript@5.4.4)': dependencies: '@commitlint/config-validator': 19.0.3 '@commitlint/execute-rule': 19.0.0 @@ -4538,7 +4541,7 @@ snapshots: '@commitlint/types': 19.0.3 chalk: 5.3.0 cosmiconfig: 9.0.0(typescript@5.4.4) - cosmiconfig-typescript-loader: 5.0.0(@types/node@20.12.6)(cosmiconfig@9.0.0(typescript@5.4.4))(typescript@5.4.4) + cosmiconfig-typescript-loader: 5.0.0(@types/node@22.5.4)(cosmiconfig@9.0.0(typescript@5.4.4))(typescript@5.4.4) lodash.isplainobject: 4.0.6 lodash.merge: 4.6.2 lodash.uniq: 4.5.0 @@ -4723,7 +4726,7 @@ snapshots: '@jest/console@29.7.0': dependencies: '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 chalk: 4.1.2 jest-message-util: 29.7.0 jest-util: 29.7.0 @@ -4736,14 +4739,14 @@ snapshots: '@jest/test-result': 29.7.0 '@jest/transform': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 ansi-escapes: 4.3.2 chalk: 4.1.2 ci-info: 3.9.0 exit: 0.1.2 graceful-fs: 4.2.10 jest-changed-files: 29.7.0 - jest-config: 29.7.0(@types/node@20.12.6) + jest-config: 29.7.0(@types/node@22.5.4) jest-haste-map: 29.7.0 jest-message-util: 29.7.0 jest-regex-util: 29.6.3 @@ -4772,7 +4775,7 @@ snapshots: dependencies: '@jest/fake-timers': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 jest-mock: 29.7.0 '@jest/expect-utils@29.7.0': @@ -4790,7 +4793,7 @@ snapshots: dependencies: '@jest/types': 29.6.3 '@sinonjs/fake-timers': 10.3.0 - '@types/node': 20.12.6 + '@types/node': 22.5.4 jest-message-util: 29.7.0 jest-mock: 29.7.0 jest-util: 29.7.0 @@ -4812,7 +4815,7 @@ snapshots: '@jest/transform': 29.7.0 '@jest/types': 29.6.3 '@jridgewell/trace-mapping': 0.3.25 - '@types/node': 20.12.6 + '@types/node': 22.5.4 chalk: 4.1.2 collect-v8-coverage: 1.0.2 exit: 0.1.2 @@ -4882,7 +4885,7 @@ snapshots: '@jest/schemas': 29.6.3 '@types/istanbul-lib-coverage': 2.0.6 '@types/istanbul-reports': 3.0.4 - '@types/node': 20.12.6 + '@types/node': 22.5.4 '@types/yargs': 17.0.32 chalk: 4.1.2 @@ -5038,7 +5041,7 @@ snapshots: '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint@8.45.0)(typescript@5.4.4) '@typescript-eslint/parser': 5.62.0(eslint@8.45.0)(typescript@5.4.4) eslint: 8.45.0 - eslint-config-airbnb: 19.0.4(eslint-plugin-import@2.29.1(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint-import-resolver-typescript@3.6.1)(eslint@8.45.0))(eslint-plugin-jsx-a11y@6.8.0(eslint@8.45.0))(eslint-plugin-react-hooks@4.6.0(eslint@8.45.0))(eslint-plugin-react@7.34.1(eslint@8.45.0))(eslint@8.45.0) + eslint-config-airbnb: 19.0.4(eslint-plugin-import@2.29.1(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint-import-resolver-typescript@3.6.1)(eslint@8.45.0))(eslint-plugin-jsx-a11y@6.8.0(eslint@8.45.0))(eslint-plugin-react-hooks@4.6.0(eslint@8.56.0))(eslint-plugin-react@7.34.1(eslint@8.45.0))(eslint@8.45.0) eslint-config-airbnb-base: 15.0.0(eslint-plugin-import@2.29.1(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint-import-resolver-typescript@3.6.1)(eslint@8.45.0))(eslint@8.45.0) eslint-config-airbnb-typescript: 17.1.0(@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint@8.45.0)(typescript@5.4.4))(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint-plugin-import@2.29.1(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint-import-resolver-typescript@3.6.1)(eslint@8.45.0))(eslint@8.45.0) eslint-config-prettier: 8.10.0(eslint@8.45.0) @@ -5046,11 +5049,11 @@ snapshots: eslint-plugin-check-file: 2.7.1(eslint@8.45.0) eslint-plugin-import: 2.29.1(@typescript-eslint/parser@7.6.0(eslint@8.56.0)(typescript@5.4.4))(eslint@8.56.0) eslint-plugin-jest-dom: 4.0.3(eslint@8.45.0) - eslint-plugin-jsx-a11y: 6.8.0(eslint@8.56.0) + eslint-plugin-jsx-a11y: 6.8.0(eslint@8.45.0) eslint-plugin-node: 11.1.0(eslint@8.45.0) eslint-plugin-prettier: 4.2.1(eslint-config-prettier@8.10.0(eslint@8.45.0))(eslint@8.45.0)(prettier@2.8.8) - eslint-plugin-react: 7.34.1(eslint@8.56.0) - eslint-plugin-react-hooks: 4.6.0(eslint@8.56.0) + eslint-plugin-react: 7.34.1(eslint@8.45.0) + eslint-plugin-react-hooks: 4.6.0(eslint@8.45.0) eslint-plugin-testing-library: 5.11.1(eslint@8.45.0)(typescript@5.4.4) optionalDependencies: typescript: 5.4.4 @@ -5061,9 +5064,9 @@ snapshots: - prettier - supports-color - '@strapi/pack-up@5.0.1-alpha.1(@types/node@20.12.6)': + '@strapi/pack-up@5.0.1-alpha.1(@types/node@22.5.4)': dependencies: - '@vitejs/plugin-react-swc': 3.6.0(vite@5.2.8(@types/node@20.12.6)) + '@vitejs/plugin-react-swc': 3.6.0(vite@5.2.8(@types/node@22.5.4)) boxen: 5.1.2 browserslist-to-esbuild: 1.2.0 chalk: 4.1.2 @@ -5082,7 +5085,7 @@ snapshots: prompts: 2.4.2 rxjs: 7.8.1 typescript: 5.4.4 - vite: 5.2.8(@types/node@20.12.6) + vite: 5.2.8(@types/node@22.5.4) yup: 0.32.9 transitivePeerDependencies: - '@swc/helpers' @@ -5190,7 +5193,7 @@ snapshots: '@types/conventional-commits-parser@5.0.0': dependencies: - '@types/node': 20.12.6 + '@types/node': 22.5.4 '@types/estree@1.0.5': {} @@ -5198,7 +5201,7 @@ snapshots: '@types/graceful-fs@4.1.9': dependencies: - '@types/node': 20.12.6 + '@types/node': 22.5.4 '@types/istanbul-lib-coverage@2.0.6': {} @@ -5225,13 +5228,13 @@ snapshots: '@types/node@12.20.55': {} - '@types/node@20.12.6': + '@types/node@22.5.4': dependencies: - undici-types: 5.26.5 + undici-types: 6.19.8 '@types/nodemon@1.19.6': dependencies: - '@types/node': 20.12.6 + '@types/node': 22.5.4 '@types/normalize-package-data@2.4.4': {} @@ -5239,7 +5242,7 @@ snapshots: '@types/prompts@2.4.9': dependencies: - '@types/node': 20.12.6 + '@types/node': 22.5.4 kleur: 3.0.3 '@types/semver@7.5.8': {} @@ -5447,10 +5450,10 @@ snapshots: '@ungap/structured-clone@1.2.0': {} - '@vitejs/plugin-react-swc@3.6.0(vite@5.2.8(@types/node@20.12.6))': + '@vitejs/plugin-react-swc@3.6.0(vite@5.2.8(@types/node@22.5.4))': dependencies: '@swc/core': 1.4.13 - vite: 5.2.8(@types/node@20.12.6) + vite: 5.2.8(@types/node@22.5.4) transitivePeerDependencies: - '@swc/helpers' @@ -5905,9 +5908,9 @@ snapshots: core-util-is@1.0.3: {} - cosmiconfig-typescript-loader@5.0.0(@types/node@20.12.6)(cosmiconfig@9.0.0(typescript@5.4.4))(typescript@5.4.4): + cosmiconfig-typescript-loader@5.0.0(@types/node@22.5.4)(cosmiconfig@9.0.0(typescript@5.4.4))(typescript@5.4.4): dependencies: - '@types/node': 20.12.6 + '@types/node': 22.5.4 cosmiconfig: 9.0.0(typescript@5.4.4) jiti: 1.21.0 typescript: 5.4.4 @@ -5921,13 +5924,13 @@ snapshots: optionalDependencies: typescript: 5.4.4 - create-jest@29.7.0(@types/node@20.12.6): + create-jest@29.7.0(@types/node@22.5.4): dependencies: '@jest/types': 29.6.3 chalk: 4.1.2 exit: 0.1.2 graceful-fs: 4.2.10 - jest-config: 29.7.0(@types/node@20.12.6) + jest-config: 29.7.0(@types/node@22.5.4) jest-util: 29.7.0 prompts: 2.4.2 transitivePeerDependencies: @@ -6279,14 +6282,14 @@ snapshots: eslint-config-airbnb-base: 15.0.0(eslint-plugin-import@2.29.1(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint-import-resolver-typescript@3.6.1)(eslint@8.45.0))(eslint@8.45.0) eslint-plugin-import: 2.29.1(@typescript-eslint/parser@7.6.0(eslint@8.56.0)(typescript@5.4.4))(eslint@8.56.0) - eslint-config-airbnb@19.0.4(eslint-plugin-import@2.29.1(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint-import-resolver-typescript@3.6.1)(eslint@8.45.0))(eslint-plugin-jsx-a11y@6.8.0(eslint@8.45.0))(eslint-plugin-react-hooks@4.6.0(eslint@8.45.0))(eslint-plugin-react@7.34.1(eslint@8.45.0))(eslint@8.45.0): + eslint-config-airbnb@19.0.4(eslint-plugin-import@2.29.1(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint-import-resolver-typescript@3.6.1)(eslint@8.45.0))(eslint-plugin-jsx-a11y@6.8.0(eslint@8.45.0))(eslint-plugin-react-hooks@4.6.0(eslint@8.56.0))(eslint-plugin-react@7.34.1(eslint@8.45.0))(eslint@8.45.0): dependencies: eslint: 8.45.0 eslint-config-airbnb-base: 15.0.0(eslint-plugin-import@2.29.1(@typescript-eslint/parser@5.62.0(eslint@8.45.0)(typescript@5.4.4))(eslint-import-resolver-typescript@3.6.1)(eslint@8.45.0))(eslint@8.45.0) eslint-plugin-import: 2.29.1(@typescript-eslint/parser@7.6.0(eslint@8.56.0)(typescript@5.4.4))(eslint@8.56.0) - eslint-plugin-jsx-a11y: 6.8.0(eslint@8.56.0) - eslint-plugin-react: 7.34.1(eslint@8.56.0) - eslint-plugin-react-hooks: 4.6.0(eslint@8.56.0) + eslint-plugin-jsx-a11y: 6.8.0(eslint@8.45.0) + eslint-plugin-react: 7.34.1(eslint@8.45.0) + eslint-plugin-react-hooks: 4.6.0(eslint@8.45.0) object.assign: 4.1.5 object.entries: 1.1.8 @@ -6396,7 +6399,7 @@ snapshots: eslint: 8.45.0 requireindex: 1.2.0 - eslint-plugin-jsx-a11y@6.8.0(eslint@8.56.0): + eslint-plugin-jsx-a11y@6.8.0(eslint@8.45.0): dependencies: '@babel/runtime': 7.24.4 aria-query: 5.3.0 @@ -6408,7 +6411,7 @@ snapshots: damerau-levenshtein: 1.0.8 emoji-regex: 9.2.2 es-iterator-helpers: 1.0.18 - eslint: 8.56.0 + eslint: 8.45.0 hasown: 2.0.2 jsx-ast-utils: 3.3.5 language-tags: 1.0.9 @@ -6434,11 +6437,11 @@ snapshots: optionalDependencies: eslint-config-prettier: 8.10.0(eslint@8.45.0) - eslint-plugin-react-hooks@4.6.0(eslint@8.56.0): + eslint-plugin-react-hooks@4.6.0(eslint@8.45.0): dependencies: - eslint: 8.56.0 + eslint: 8.45.0 - eslint-plugin-react@7.34.1(eslint@8.56.0): + eslint-plugin-react@7.34.1(eslint@8.45.0): dependencies: array-includes: 3.1.8 array.prototype.findlast: 1.2.5 @@ -6447,7 +6450,7 @@ snapshots: array.prototype.tosorted: 1.1.3 doctrine: 2.1.0 es-iterator-helpers: 1.0.18 - eslint: 8.56.0 + eslint: 8.45.0 estraverse: 5.3.0 jsx-ast-utils: 3.3.5 minimatch: 3.1.2 @@ -7246,7 +7249,7 @@ snapshots: '@jest/expect': 29.7.0 '@jest/test-result': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 chalk: 4.1.2 co: 4.6.0 dedent: 1.5.1 @@ -7266,16 +7269,16 @@ snapshots: - babel-plugin-macros - supports-color - jest-cli@29.7.0(@types/node@20.12.6): + jest-cli@29.7.0(@types/node@22.5.4): dependencies: '@jest/core': 29.7.0 '@jest/test-result': 29.7.0 '@jest/types': 29.6.3 chalk: 4.1.2 - create-jest: 29.7.0(@types/node@20.12.6) + create-jest: 29.7.0(@types/node@22.5.4) exit: 0.1.2 import-local: 3.1.0 - jest-config: 29.7.0(@types/node@20.12.6) + jest-config: 29.7.0(@types/node@22.5.4) jest-util: 29.7.0 jest-validate: 29.7.0 yargs: 17.7.2 @@ -7285,7 +7288,7 @@ snapshots: - supports-color - ts-node - jest-config@29.7.0(@types/node@20.12.6): + jest-config@29.7.0(@types/node@22.5.4): dependencies: '@babel/core': 7.24.4 '@jest/test-sequencer': 29.7.0 @@ -7310,7 +7313,7 @@ snapshots: slash: 3.0.0 strip-json-comments: 3.1.1 optionalDependencies: - '@types/node': 20.12.6 + '@types/node': 22.5.4 transitivePeerDependencies: - babel-plugin-macros - supports-color @@ -7339,7 +7342,7 @@ snapshots: '@jest/environment': 29.7.0 '@jest/fake-timers': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 jest-mock: 29.7.0 jest-util: 29.7.0 @@ -7349,7 +7352,7 @@ snapshots: dependencies: '@jest/types': 29.6.3 '@types/graceful-fs': 4.1.9 - '@types/node': 20.12.6 + '@types/node': 22.5.4 anymatch: 3.1.3 fb-watchman: 2.0.2 graceful-fs: 4.2.10 @@ -7388,7 +7391,7 @@ snapshots: jest-mock@29.7.0: dependencies: '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 jest-util: 29.7.0 jest-pnp-resolver@1.2.3(jest-resolve@29.7.0): @@ -7423,7 +7426,7 @@ snapshots: '@jest/test-result': 29.7.0 '@jest/transform': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 chalk: 4.1.2 emittery: 0.13.1 graceful-fs: 4.2.10 @@ -7451,7 +7454,7 @@ snapshots: '@jest/test-result': 29.7.0 '@jest/transform': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 chalk: 4.1.2 cjs-module-lexer: 1.2.3 collect-v8-coverage: 1.0.2 @@ -7497,7 +7500,7 @@ snapshots: jest-util@29.7.0: dependencies: '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 chalk: 4.1.2 ci-info: 3.9.0 graceful-fs: 4.2.10 @@ -7516,7 +7519,7 @@ snapshots: dependencies: '@jest/test-result': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 20.12.6 + '@types/node': 22.5.4 ansi-escapes: 4.3.2 chalk: 4.1.2 emittery: 0.13.1 @@ -7525,17 +7528,17 @@ snapshots: jest-worker@29.7.0: dependencies: - '@types/node': 20.12.6 + '@types/node': 22.5.4 jest-util: 29.7.0 merge-stream: 2.0.0 supports-color: 8.1.1 - jest@29.7.0(@types/node@20.12.6): + jest@29.7.0(@types/node@22.5.4): dependencies: '@jest/core': 29.7.0 '@jest/types': 29.6.3 import-local: 3.1.0 - jest-cli: 29.7.0(@types/node@20.12.6) + jest-cli: 29.7.0(@types/node@22.5.4) transitivePeerDependencies: - '@types/node' - babel-plugin-macros @@ -8707,7 +8710,7 @@ snapshots: undefsafe@2.0.5: {} - undici-types@5.26.5: {} + undici-types@6.19.8: {} unicorn-magic@0.1.0: {} @@ -8736,13 +8739,13 @@ snapshots: spdx-correct: 3.2.0 spdx-expression-parse: 3.0.1 - vite@5.2.8(@types/node@20.12.6): + vite@5.2.8(@types/node@22.5.4): dependencies: esbuild: 0.20.2 postcss: 8.4.38 rollup: 4.14.1 optionalDependencies: - '@types/node': 20.12.6 + '@types/node': 22.5.4 fsevents: 2.3.3 walker@1.0.8: diff --git a/src/index.ts b/src/index.ts index 1d37c8c..c507f2d 100644 --- a/src/index.ts +++ b/src/index.ts @@ -12,7 +12,7 @@ const createCLI = async (argv: string[], command = new Command()) => { // Help command command.helpOption('-h, --help', 'Display help for command'); - command.addHelpCommand('help [command]', 'Display help for command'); + command.helpCommand('help [command]', 'Display help for command'); command.version( // eslint-disable-next-line @typescript-eslint/no-var-requires