Skip to content

Commit

Permalink
refactor: simplify initial prompt message for tsconfig path
Browse files Browse the repository at this point in the history
  • Loading branch information
sadeghbarati committed Nov 14, 2024
1 parent 7a13dd7 commit 1b53018
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions packages/cli/src/commands/init.ts
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,8 @@ export async function promptForConfig(
name: 'tsConfigPath',
message: (prev, values) => `Where is your ${highlight(values.typescript ? 'tsconfig.json' : 'jsconfig.json')} file?`,
initial: (prev, values) => {
const prefix = values.framework === 'nuxt' ? '.nuxt/' : './'
const path = values.framework === 'nuxt' ? 'tsconfig.json' : values.typescript ? 'tsconfig.json' : 'jsconfig.json'
return prefix + path
const path = values.typescript ? './tsconfig.json' : './jsconfig.json'
return path
},
},
{
Expand Down

0 comments on commit 1b53018

Please sign in to comment.