vako 1.3.16 → 1.3.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -93,8 +93,17 @@ class SetupWizard {
93
93
  console.clear();
94
94
  await this.showWelcome();
95
95
  await this.gatherProjectInfo();
96
- await this.selectCodeType();
97
- await this.selectLanguage();
96
+
97
+ // Sélection du type de code (EJS, TypeScript, Next.js)
98
+ if (typeof this.selectCodeType === 'function') {
99
+ await this.selectCodeType();
100
+ }
101
+
102
+ // Sélection de la langue du site
103
+ if (typeof this.selectLanguage === 'function') {
104
+ await this.selectLanguage();
105
+ }
106
+
98
107
  await this.selectTemplate();
99
108
  await this.selectFeatures();
100
109
  await this.configureDatabase();
@@ -234,21 +243,28 @@ class SetupWizard {
234
243
  }
235
244
  ];
236
245
 
237
- const { codeType } = await inquirer.prompt([{
238
- type: 'list',
239
- name: 'codeType',
240
- message: '🎯 Select your preferred code type:',
241
- choices: codeTypeChoices.map(choice => ({
242
- name: choice.name,
243
- value: choice.value
244
- })),
245
- pageSize: 10
246
- }]);
246
+ try {
247
+ const { codeType } = await inquirer.prompt([{
248
+ type: 'list',
249
+ name: 'codeType',
250
+ message: '🎯 Select your preferred code type:',
251
+ choices: codeTypeChoices.map(choice => ({
252
+ name: choice.name,
253
+ value: choice.value
254
+ })),
255
+ pageSize: 10
256
+ }]);
247
257
 
248
- this.config.codeType = codeType;
249
-
250
- const selectedChoice = codeTypeChoices.find(c => c.value === codeType);
251
- console.log(chalk.gray(`\n✓ Selected: ${selectedChoice.description}\n`));
258
+ this.config.codeType = codeType || 'ejs'; // Par défaut EJS
259
+
260
+ const selectedChoice = codeTypeChoices.find(c => c.value === codeType);
261
+ if (selectedChoice) {
262
+ console.log(chalk.gray(`\n✓ Selected: ${selectedChoice.description}\n`));
263
+ }
264
+ } catch (error) {
265
+ console.error(chalk.red('Error selecting code type:'), error.message);
266
+ this.config.codeType = 'ejs'; // Par défaut EJS en cas d'erreur
267
+ }
252
268
  }
253
269
 
254
270
  /**
package/bin/vako.js CHANGED
@@ -21,7 +21,7 @@ const program = new Command();
21
21
  program
22
22
  .name('vako')
23
23
  .description('Vako Framework CLI')
24
- .version('1.3.16');
24
+ .version('1.3.17');
25
25
 
26
26
  // ============= DEV COMMAND =============
27
27
  program
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vako",
3
- "version": "1.3.16",
3
+ "version": "1.3.17",
4
4
  "description": "🚀 Ultra-modern Node.js framework with hot reload, plugins, authentication, TypeScript support, and Next.js integration",
5
5
  "main": "index.js",
6
6
  "types": "types/index.d.ts",