From d7824e0e2523703662b731945229e2fae88708ae Mon Sep 17 00:00:00 2001 From: Christopher Ehrlich Date: Mon, 16 Oct 2023 00:45:17 +0200 Subject: [PATCH] feat: show callout when scaffolding with app router (#1595) --- .changeset/light-steaks-happen.md | 5 +++++ cli/src/helpers/logNextSteps.ts | 9 ++++++++- cli/src/index.ts | 1 + 3 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 .changeset/light-steaks-happen.md diff --git a/.changeset/light-steaks-happen.md b/.changeset/light-steaks-happen.md new file mode 100644 index 0000000000..983ecfd174 --- /dev/null +++ b/.changeset/light-steaks-happen.md @@ -0,0 +1,5 @@ +--- +"create-t3-app": minor +--- + +show callout when scaffolding with app router diff --git a/cli/src/helpers/logNextSteps.ts b/cli/src/helpers/logNextSteps.ts index 66f607e470..a51d31ffc0 100644 --- a/cli/src/helpers/logNextSteps.ts +++ b/cli/src/helpers/logNextSteps.ts @@ -8,11 +8,12 @@ import { isInsideGitRepo, isRootGitRepo } from "./git.js"; export const logNextSteps = async ({ projectName = DEFAULT_APP_NAME, packages, + appRouter, noInstall, projectDir, }: Pick< InstallerOptions, - "projectName" | "packages" | "noInstall" | "projectDir" + "projectName" | "packages" | "noInstall" | "projectDir" | "appRouter" >) => { const pkgManager = getUserPkgManager(); @@ -46,6 +47,12 @@ export const logNextSteps = async ({ } logger.info(` git commit -m "initial commit"`); + if (appRouter) { + logger.warn( + `\nThank you for trying out the App Router option. If you encounter any issues, please open an issue!` + ); + } + if (packages?.drizzle.inUse) { logger.warn( `\nThank you for trying out the new Drizzle option. If you encounter any issues, please open an issue!`, diff --git a/cli/src/index.ts b/cli/src/index.ts index ba7d16ae86..5657401ea2 100644 --- a/cli/src/index.ts +++ b/cli/src/index.ts @@ -94,6 +94,7 @@ const main = async () => { await logNextSteps({ projectName: appDir, packages: usePackages, + appRouter, noInstall, projectDir, });