@inquirer/prompts 6.0.0 → 7.0.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/README.md CHANGED
@@ -295,6 +295,22 @@ exec < /dev/tty
295
295
  node my-script.js
296
296
  ```
297
297
 
298
+ ## Using with nodemon
299
+
300
+ When using inquirer prompts with nodemon, you need to pass the `--no-stdin` flag for everything to work as expected.
301
+
302
+ ```sh
303
+ npx nodemon ./packages/demo/demos/password.mjs --no-stdin
304
+ ```
305
+
306
+ Note that for most of you, you'll be able to use the new watch-mode built-in Node. This mode works out of the box with inquirer.
307
+
308
+ ```sh
309
+ # One of depending on your need
310
+ node --watch script.js
311
+ node --watch-path=packages/ packages/demo/
312
+ ```
313
+
298
314
  ## Wait for config
299
315
 
300
316
  Maybe some question configuration require to await a value.
@@ -0,0 +1,3 @@
1
+ {
2
+ "type": "commonjs"
3
+ }
@@ -0,0 +1,3 @@
1
+ {
2
+ "type": "module"
3
+ }
package/package.json CHANGED
@@ -1,16 +1,7 @@
1
1
  {
2
2
  "name": "@inquirer/prompts",
3
- "version": "6.0.0",
3
+ "version": "7.0.0",
4
4
  "description": "Inquirer prompts, combined in a single package",
5
- "main": "./dist/cjs/index.js",
6
- "typings": "./dist/cjs/types/index.d.ts",
7
- "files": [
8
- "dist/**/*"
9
- ],
10
- "repository": {
11
- "type": "git",
12
- "url": "https://github.com/SBoudrias/Inquirer.js.git"
13
- },
14
5
  "keywords": [
15
6
  "answer",
16
7
  "answers",
@@ -52,45 +43,67 @@
52
43
  "types",
53
44
  "typescript"
54
45
  ],
55
- "author": "Simon Boudrias <admin@simonboudrias.com>",
56
- "license": "MIT",
57
- "scripts": {
58
- "tsc": "yarn run tsc:esm && yarn run tsc:cjs",
59
- "tsc:esm": "rm -rf dist/esm && tsc -p ./tsconfig.json",
60
- "tsc:cjs": "rm -rf dist/cjs && tsc -p ./tsconfig.cjs.json && node ../../tools/fix-ext.mjs",
61
- "attw": "attw --pack"
62
- },
63
- "engines": {
64
- "node": ">=18"
46
+ "homepage": "https://github.com/SBoudrias/Inquirer.js/blob/main/packages/prompts/README.md",
47
+ "repository": {
48
+ "type": "git",
49
+ "url": "https://github.com/SBoudrias/Inquirer.js.git"
65
50
  },
51
+ "license": "MIT",
52
+ "author": "Simon Boudrias <admin@simonboudrias.com>",
53
+ "sideEffects": false,
54
+ "type": "module",
66
55
  "exports": {
56
+ "./package.json": "./package.json",
67
57
  ".": {
68
58
  "import": {
69
- "types": "./dist/esm/types/index.d.mts",
70
- "default": "./dist/esm/index.mjs"
59
+ "types": "./dist/esm/index.d.ts",
60
+ "default": "./dist/esm/index.js"
71
61
  },
72
62
  "require": {
73
- "types": "./dist/cjs/types/index.d.ts",
74
- "default": "./dist/cjs/index.js"
63
+ "types": "./dist/commonjs/index.d.ts",
64
+ "default": "./dist/commonjs/index.js"
75
65
  }
76
66
  }
77
67
  },
68
+ "main": "./dist/commonjs/index.js",
69
+ "module": "./dist/esm/index.js",
70
+ "types": "./dist/commonjs/index.d.ts",
71
+ "files": [
72
+ "dist"
73
+ ],
74
+ "scripts": {
75
+ "attw": "attw --pack",
76
+ "tsc": "tshy"
77
+ },
78
78
  "dependencies": {
79
- "@inquirer/checkbox": "^3.0.0",
80
- "@inquirer/confirm": "^4.0.0",
81
- "@inquirer/editor": "^3.0.0",
82
- "@inquirer/expand": "^3.0.0",
83
- "@inquirer/input": "^3.0.0",
84
- "@inquirer/number": "^2.0.0",
85
- "@inquirer/password": "^3.0.0",
86
- "@inquirer/rawlist": "^3.0.0",
87
- "@inquirer/search": "^2.0.0",
88
- "@inquirer/select": "^3.0.0"
79
+ "@inquirer/checkbox": "^4.0.0",
80
+ "@inquirer/confirm": "^5.0.0",
81
+ "@inquirer/editor": "^4.0.0",
82
+ "@inquirer/expand": "^4.0.0",
83
+ "@inquirer/input": "^4.0.0",
84
+ "@inquirer/number": "^3.0.0",
85
+ "@inquirer/password": "^4.0.0",
86
+ "@inquirer/rawlist": "^4.0.0",
87
+ "@inquirer/search": "^3.0.0",
88
+ "@inquirer/select": "^4.0.0"
89
89
  },
90
90
  "devDependencies": {
91
- "@inquirer/type": "^1.5.4"
91
+ "@arethetypeswrong/cli": "^0.16.4",
92
+ "@inquirer/type": "^3.0.0",
93
+ "@repo/tsconfig": "workspace:*",
94
+ "tshy": "^3.0.2"
92
95
  },
93
- "homepage": "https://github.com/SBoudrias/Inquirer.js/blob/main/packages/prompts/README.md",
94
- "sideEffects": false,
95
- "gitHead": "5fe03a4686d349d0d6cf281f86f12a4f7c992ad4"
96
+ "engines": {
97
+ "node": ">=18"
98
+ },
99
+ "tshy": {
100
+ "exclude": [
101
+ "src/**/*.test.ts"
102
+ ],
103
+ "exports": {
104
+ "./package.json": "./package.json",
105
+ ".": "./src/index.ts"
106
+ }
107
+ },
108
+ "gitHead": "483189975eb5ea7d214c265a5ce108544c2bf1a5"
96
109
  }
@@ -1,9 +0,0 @@
1
- export { default as checkbox, Separator } from '@inquirer/checkbox';
2
- export { default as editor } from '@inquirer/editor';
3
- export { default as confirm } from '@inquirer/confirm';
4
- export { default as input } from '@inquirer/input';
5
- export { default as number } from '@inquirer/number';
6
- export { default as expand } from '@inquirer/expand';
7
- export { default as rawlist } from '@inquirer/rawlist';
8
- export { default as password } from '@inquirer/password';
9
- export { default as select } from '@inquirer/select';
File without changes
File without changes
File without changes
File without changes