@optique/core 1.4.0-dev.2725 → 1.4.0-dev.2728

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@optique/core",
3
- "version": "1.4.0-dev.2725",
3
+ "version": "1.4.0-dev.2728",
4
4
  "description": "Type-safe combinatorial command-line interface parser",
5
5
  "keywords": [
6
6
  "CLI",
@@ -245,7 +245,7 @@
245
245
  },
246
246
  "sideEffects": false,
247
247
  "devDependencies": {
248
- "@optique/env": "1.4.0-dev.2725+a2d21dc2",
248
+ "@optique/env": "1.4.0-dev.2728+5829a43f",
249
249
  "@types/node": "^24.0.0",
250
250
  "fast-check": "^4.7.0",
251
251
  "tsdown": "^0.13.0",
@@ -56,15 +56,14 @@ Core rules
56
56
  For a multi-level chain, wrap the middle derivation too:
57
57
  `dependency(source.deriveSync(...))`. Optique resolves such chains by
58
58
  dependency order, independently of object/tuple field order.
59
- - Use `derivePromptConfig(source, resolver)` (from *@optique/prompt*,
60
- re-exported by *@optique/inquirer* and *@optique/clack*) when a prompt's
61
- choices or message depend on another parsed value. The resolver may be
62
- async and runs only at the real prompt fallback, after the named sources
63
- resolve; pass `[sourceA, sourceB]` when it reads several sources. The
64
- resolver's prompt kind must return the wrapped parser's value type. Derive
65
- the wrapped parser separately when the CLI domain should change, and make
66
- it a dependency source only if another consumer needs its answer. Pass a
67
- lone resolver for fetched choices, forwarding its `signal` to the fetch.
59
+ - Use `derivePromptConfig(source, resolver)` from *@optique/prompt* or its
60
+ adapter re-exports for choices or messages that depend on parsed values.
61
+ Async resolvers run at the real fallback after sources resolve; pass
62
+ `[sourceA, sourceB]` for several sources. Return a prompt kind matching the
63
+ parser's value type. Derive the CLI parser separately; make it a dependency
64
+ source only if another consumer needs its answer. Use a lone resolver for
65
+ fetched choices and forward its `signal`. Clack's third argument accepts
66
+ `pendingMessage` for a resolver spinner; omit it for silent prompter tests.
68
67
  - Pass `{ validate, maxAttempts, signal }` as a generated prompt wrapper's
69
68
  third argument, including `prompt()` from *@optique/inquirer* and
70
69
  *@optique/clack*. The validator returns `undefined` to accept the prompted