@jakubmazanec/cli 0.5.6 → 0.5.7-next.4df71cb5
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/build/ui/useProgram.js.map +2 -2
- package/package.json +27 -27
- package/source/ui/useProgram.ts +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../source/ui/useProgram.ts"],
|
|
4
|
-
"sourcesContent": ["import {useApp} from 'ink';\nimport {useCallback, useContext} from 'react';\nimport {useErrorBoundary} from 'react-error-boundary';\n\nimport {programContext} from './internals.js';\n\n/**\n * A React hook for accessing {@link Program} instance and `exit` function that is used for showing an error (via an error boundary) and exiting.\n */\nexport function useProgram() {\n let {showBoundary} = useErrorBoundary();\n let {exit: appExit} = useApp();\n let {program} = useContext(programContext);\n\n let exit = useCallback(\n (error: unknown) => {\n process.exitCode = 1;\n\n showBoundary(error);\n appExit(error
|
|
5
|
-
"mappings": "AAAA,SAAQ,cAAa;AACrB,SAAQ,aAAa,kBAAiB;AACtC,SAAQ,wBAAuB;AAE/B,SAAQ,sBAAqB;AAKtB,gBAAS,aAAa;AAC3B,MAAI,EAAC,aAAY,IAAI,iBAAiB;AACtC,MAAI,EAAC,MAAM,QAAO,IAAI,OAAO;AAC7B,MAAI,EAAC,QAAO,IAAI,WAAW,cAAc;AAEzC,MAAI,OAAO;AAAA,IACT,CAAC,UAAmB;AAClB,cAAQ,WAAW;AAEnB,mBAAa,KAAK;AAClB,cAAQ,
|
|
4
|
+
"sourcesContent": ["import {useApp} from 'ink';\nimport {useCallback, useContext} from 'react';\nimport {useErrorBoundary} from 'react-error-boundary';\n\nimport {programContext} from './internals.js';\n\n/**\n * A React hook for accessing {@link Program} instance and `exit` function that is used for showing an error (via an error boundary) and exiting.\n */\nexport function useProgram() {\n let {showBoundary} = useErrorBoundary();\n let {exit: appExit} = useApp();\n let {program} = useContext(programContext);\n\n let exit = useCallback(\n (error: unknown) => {\n process.exitCode = 1;\n\n showBoundary(error);\n appExit(error);\n },\n [appExit, showBoundary],\n );\n\n return {program, exit};\n}\n"],
|
|
5
|
+
"mappings": "AAAA,SAAQ,cAAa;AACrB,SAAQ,aAAa,kBAAiB;AACtC,SAAQ,wBAAuB;AAE/B,SAAQ,sBAAqB;AAKtB,gBAAS,aAAa;AAC3B,MAAI,EAAC,aAAY,IAAI,iBAAiB;AACtC,MAAI,EAAC,MAAM,QAAO,IAAI,OAAO;AAC7B,MAAI,EAAC,QAAO,IAAI,WAAW,cAAc;AAEzC,MAAI,OAAO;AAAA,IACT,CAAC,UAAmB;AAClB,cAAQ,WAAW;AAEnB,mBAAa,KAAK;AAClB,cAAQ,KAAK;AAAA,IACf;AAAA,IACA,CAAC,SAAS,YAAY;AAAA,EACxB;AAEA,SAAO,EAAC,SAAS,KAAI;AACvB;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jakubmazanec/cli",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.7-next.4df71cb5",
|
|
4
4
|
"description": "TypeScript-first library for building CLIs.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -17,9 +17,9 @@
|
|
|
17
17
|
"source"
|
|
18
18
|
],
|
|
19
19
|
"scripts": {
|
|
20
|
-
"build": "del-cli build tsconfig.tsbuildinfo && esbuild \"source/**/*\" --platform=node --target=node24.
|
|
20
|
+
"build": "del-cli build tsconfig.tsbuildinfo && esbuild \"source/**/*\" --platform=node --target=node24.21 --outdir=build --sourcemap && tsc",
|
|
21
21
|
"clean": "del-cli coverage build *.tsbuildinfo",
|
|
22
|
-
"develop": "concurrently \"esbuild \"source/**/*\" --platform=node --target=node24.
|
|
22
|
+
"develop": "concurrently \"esbuild \"source/**/*\" --platform=node --target=node24.21 --outdir=build --sourcemap --watch\" \"tsc --watch\"",
|
|
23
23
|
"document": "del-cli docs && typedoc --options typedoc.config.cjs",
|
|
24
24
|
"format": "prettier . --write --ignore-unknown",
|
|
25
25
|
"lint": "eslint .",
|
|
@@ -27,46 +27,46 @@
|
|
|
27
27
|
"typecheck": "tsc --project tsconfig.typecheck.json"
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@jakubmazanec/args": "
|
|
31
|
-
"@jakubmazanec/error": "
|
|
32
|
-
"@jakubmazanec/ts-utils": "
|
|
33
|
-
"@jakubmazanec/zod-utils": "
|
|
30
|
+
"@jakubmazanec/args": "2.0.19-next.4df71cb5",
|
|
31
|
+
"@jakubmazanec/error": "3.0.19-next.4df71cb5",
|
|
32
|
+
"@jakubmazanec/ts-utils": "3.0.20-next.4df71cb5",
|
|
33
|
+
"@jakubmazanec/zod-utils": "3.0.5-next.4df71cb5",
|
|
34
34
|
"chalk": "^5.6.2",
|
|
35
|
-
"fs-extra": "^11.
|
|
35
|
+
"fs-extra": "^11.4.1",
|
|
36
36
|
"latest-version": "^9.0.0",
|
|
37
37
|
"lodash": "^4.18.1",
|
|
38
|
-
"react-error-boundary": "^6.1.
|
|
39
|
-
"zod": "^4.
|
|
38
|
+
"react-error-boundary": "^6.1.6",
|
|
39
|
+
"zod": "^4.6.5"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
|
-
"@jakubmazanec/eslint-config": "
|
|
42
|
+
"@jakubmazanec/eslint-config": "5.0.1-next.4df71cb5",
|
|
43
43
|
"@types/fs-extra": "^11.0.4",
|
|
44
|
-
"@types/lodash": "^4.17.
|
|
45
|
-
"@types/node": "^24.
|
|
46
|
-
"@types/react": "^19.
|
|
47
|
-
"@vitest/coverage-v8": "^4.1.
|
|
48
|
-
"concurrently": "^10.0.
|
|
44
|
+
"@types/lodash": "^4.17.25",
|
|
45
|
+
"@types/node": "^24.19.1",
|
|
46
|
+
"@types/react": "^19.3.0",
|
|
47
|
+
"@vitest/coverage-v8": "^4.1.11",
|
|
48
|
+
"concurrently": "^10.0.6",
|
|
49
49
|
"cross-env": "^10.1.0",
|
|
50
50
|
"del-cli": "^7.0.0",
|
|
51
|
-
"esbuild": "^0.28.
|
|
52
|
-
"eslint": "^9.39.
|
|
53
|
-
"ink": "^6.
|
|
51
|
+
"esbuild": "^0.28.2",
|
|
52
|
+
"eslint": "^9.39.5",
|
|
53
|
+
"ink": "^6.8.0",
|
|
54
54
|
"ink-testing-library": "^4.0.0",
|
|
55
|
-
"prettier": "^3.9.
|
|
55
|
+
"prettier": "^3.9.9",
|
|
56
56
|
"prettier-plugin-packagejson": "^2.5.22",
|
|
57
|
-
"react": "^19.
|
|
57
|
+
"react": "^19.3.0",
|
|
58
58
|
"typedoc": "^0.28.20",
|
|
59
|
-
"typedoc-plugin-markdown": "^4.
|
|
60
|
-
"typescript": "^6.0.
|
|
61
|
-
"vitest": "^4.1.
|
|
59
|
+
"typedoc-plugin-markdown": "^4.13.1",
|
|
60
|
+
"typescript": "^6.0.3",
|
|
61
|
+
"vitest": "^4.1.11"
|
|
62
62
|
},
|
|
63
63
|
"peerDependencies": {
|
|
64
64
|
"ink": "6.x",
|
|
65
65
|
"react": "19.x"
|
|
66
66
|
},
|
|
67
|
-
"packageManager": "npm@11.
|
|
67
|
+
"packageManager": "npm@11.21.0",
|
|
68
68
|
"engines": {
|
|
69
|
-
"node": "^24.
|
|
70
|
-
"npm": "^11.
|
|
69
|
+
"node": "^24.21.0",
|
|
70
|
+
"npm": "^11.21.0"
|
|
71
71
|
}
|
|
72
72
|
}
|