askeroo
Version:
A modern CLI prompt library with flow control, history navigation, and conditional prompts
24 lines • 708 B
JavaScript
import { ask, group, text } from "../src/index.js";
const flow = async () => {
const answers = await group(async () => {
return {
type: await text({ label: "Type" }),
framework: await text({ label: "Framework" }),
typescript: await text({ label: "TypeScript" }),
template: await text({ label: "Template" }),
};
});
return { answers };
};
(async () => {
try {
const result = await ask(flow);
console.log("\nResult:", JSON.stringify(result, null, 2));
}
catch (error) {
console.error("Error:", error);
process.exit(1);
}
})();
//# sourceMappingURL=progressive.js.map