github SBoudrias/Inquirer.js @inquirer/core@2.2.0

latest releases: @inquirer/prompts@7.0.1, inquirer@12.0.1, @inquirer/testing@2.1.36...
16 months ago
  • When setting a state (useState), it'll only re-renders if the value changed.
  • When setting multiple states at once, we'll only trigger one re-renders if it happens inside a hook callback (previously each state change triggered one re-render.)

If you're setting multiple state in a callback from an async function (like setTimeout or a network call), those will not be merged in a single re-renders. For those case, you're better using a state object holding all values to reduce the amount of re-renders. Open to discuss this in #1251

Don't miss a new Inquirer.js release

NewReleases is sending notifications on new releases.