Default to JS

This commit is contained in:
Tat Dat Duong
2025-01-22 16:04:25 +01:00
parent b7cccf8615
commit e36964db38
-14
View File
@@ -165,22 +165,8 @@ async function createNew(projectPath?: string, templateId?: string) {
process.exit(0);
}
const userLaunguage = await select({
message: "Choose language",
options: [
{ value: "js", label: "TypeScript 🌐" },
{ value: "python", label: "Python 🐍" },
],
});
if (isCancel(userLaunguage)) {
cancel("Operation cancelled");
process.exit(0);
}
const template = TEMPLATES[templateChoice as keyof typeof TEMPLATES];
if (!template) throw new Error("Invalid template choice");
language = userLaunguage as "js" | "python";
templateUrl = template[language];
}