docs/tutorials/ask-for-next.js
Beginner7 min

Ask for Next.js

Create an app, start it, and build for production. Each Ask is print-only. You run the command in the repo.

What you will do

These simulations assume a Next.js app with pnpm. If the printed command does not match your lockfile, use the alternative or fix it before you paste.

01Create the app

simulated — nothing here is executed.
$ recall "create a new next.js app with typescript and app router using pnpm"  pnpm create next-app@latest my-app --typescript --app --eslint --no-tailwind --no-src-dir --import-alias '@/*' --use-pnpm Scaffolds a Next.js app in my-app with the App Router and TypeScript.  shell: zsh risk: SAFE source: recall agent ai left this month: 19  alt npx create-next-app@latest my-app  Ask mode does not run commands. Copy or save this yourself. ? Save this command? No
you run this
pnpm create next-app@latest my-app --typescript --app --eslint --no-tailwind --no-src-dir --import-alias '@/*' --use-pnpm

02Start the project

simulated — nothing here is executed.
$ recall "start the next.js app"  pnpm dev Runs the Next.js dev server. Default URL is http://localhost:3000.  shell: zsh risk: SAFE source: recall agent ai left this month: 18  alt npm run dev alt yarn dev  Ask mode does not run commands. Copy or save this yourself. ? Save this command? No
simulated next output after you paste
$ pnpm dev ▲ Next.js 16 - Local: http://localhost:3000

03Production build

simulated — nothing here is executed.
$ recall "build the next app for production"  pnpm build Creates an optimized production build. Run pnpm start afterward to serve it.  shell: zsh risk: SAFE source: recall agent ai left this month: 17  Ask mode does not run commands. Copy or save this yourself. ? Save this command? No

04Name it so vault can answer later

simulated — nothing here is executed.
$ recall "start the next.js app"  pnpm dev Runs the Next.js dev server.  shell: zsh risk: SAFE source: recall agent ai left this month: 17  Ask mode does not run commands. Copy or save this yourself. ? Save this command? Yes? Name (optional): next-dev? Tags (optional): next,dev Saved as "next-dev" [next,dev].

After it is saved, rec "start the next.js app" can hit from your vault.

// what's next
React / Vite Asks if you are not on Next Docker Compose and port 3000