Skip to content

Commit

Permalink
chore(create-next-app): add logic for different templates
Browse files Browse the repository at this point in the history
  • Loading branch information
samcx committed May 8, 2024
1 parent 8a83458 commit 921b3e6
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions packages/create-next-app/create-app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,19 @@ export async function createApp({
const mode: TemplateMode = typescript ? 'ts' : 'js'
const template: TemplateType = appRouter
? tailwind
? 'app-tw'
: 'app'
? empty
? 'app-tw-empty'
: 'app-tw'
: empty
? 'app-empty'
: 'app'
: tailwind
? 'default-tw'
: 'default'
? empty
? 'default-tw-empty'
: 'default-tw'
: empty
? 'default-empty'
: 'default'

if (example) {
let repoUrl: URL | undefined
Expand Down Expand Up @@ -235,7 +243,6 @@ export async function createApp({
srcDir,
importAlias,
skipInstall,
empty,
})
}

Expand Down

0 comments on commit 921b3e6

Please sign in to comment.