Skip to content

armgit / E2B

Public Imported from GitHub
0

Open-source, secure environment with real-world tools for enterprise-grade agents.

334 B
Raw Blame
export async function confirm(text: string, defaultAnswer = false) {
  const inquirer = await import('inquirer')
  const confirmAnswers = await inquirer.default.prompt([
    {
      name: 'confirm',
      type: 'confirm',
      default: defaultAnswer,
      message: text,
    },
  ])

  return confirmAnswers['confirm'] as boolean
}