import { prompt } from 'enquirer' export const input = async (message: string, type: string, options?: any): Promise => { try { const { data } = (await prompt({ name: 'data', message, type, ...options })) as any return data } catch (error) { return null } }