Skip to content

Releases: SBoudrias/Inquirer.js

@inquirer/checkbox@1.5.0

07 Nov 22:24
a318aec
Compare
Choose a tag to compare

New features!

  • New required prompt config. Makes sure at least one choice is selected.
  • New validate prompt config. Provide a function that'll validate the user selection with any logic you want (like enforcing a min or max selection amount.) Please use this config with parsimony since complicated validation scheme can lead to sub-optimal UX!

@inquirer/select@1.3.0

03 Oct 20:38
c88aaca
Compare
Choose a tag to compare
  • Now supports the loop: false option. (This feature was available on inquirer, but not ported to new prompts yet)

@inquirer/core@5.1.0

03 Oct 20:37
c88aaca
Compare
Choose a tag to compare
  • Introduces a new useMemo hook.

@inquirer/checkbox@1.4.0

03 Oct 20:38
c88aaca
Compare
Choose a tag to compare
  • Now supports the loop: false option. (This feature was available on inquirer, but not ported to new prompts yet)

@inquirer/core@5.0.1

25 Sep 22:31
8578406
Compare
Choose a tag to compare
  • Bugfix: infinite loop occurring when changing state from useEffect body. See #1307

@inquirer/prompts@3.1.1

10 Sep 16:36
c2d1c5f
Compare
Choose a tag to compare
  • Fix: There was an issue with ESM/CJS imports interoperability that should now be fixed. Ref #1297

@inquirer/core@5.0.0

10 Sep 16:40
c2d1c5f
Compare
Choose a tag to compare
  • Breaking (low chance): The typing always defined a validate config; but it was rarely used. It's been removed and prompts relying on it are expected to handle it on their own (no default value.) The types were updated accordingly and will raise issue if you're using typescript.
  • Deprecation warning (TS only): If your custom prompt extended AsyncPromptConfig, it's been deprecated in favour of PromptConfig
- import type { AsyncPromptConfig } from '@inquirer/core';
+ import type { PromptConfig } from '@inquirer/core';

- type Config = AsyncPromptConfig & { custom: 'value' };
+ type Config = PromptConfig<{ custom: 'value' }>;

Note: Old interface works for now, but is marked as deprecated.

@inquirer/prompts@3.1.0

09 Sep 21:29
f5c544a
Compare
Choose a tag to compare
  • Review how force exit events are handled to make sure we restore the cursor properly.
  • Various dependencies bump (including TS 5.2.2)

@inquirer/core@4.1.0

09 Sep 21:28
f5c544a
Compare
Choose a tag to compare
  • Review how force exit events are handled to make sure we restore the cursor properly.
  • Various dependencies bump (including TS 5.2.2)

@inquirer/core@4.0.0

27 Aug 17:51
ea5baff
Compare
Choose a tag to compare

Major rewrite of the core to rely on node's async hooks for better isolation of each prompts. Relying on this means each prompt context is fully isolated (previously it would rely on the module level context.)

We expect this update to be transparent to most. Though some custom event handlers within useEffect could stop working. If you find any issues there, first please let us know - there might be thing to improve internally to make it transparent. The manual fix will likely be to explicitly define events callback as an AsyncResource.

Let us know how this works for you!