August 11, 2023

Next.js Starter Template with built in Layout components

Next.js Starter Template with built in Layout components

This is a template for rapidly starting Next.js TypeScript projects with built in components relating to page layout. Inspired by @clxmente's template with a few added dependencies + a components/layout folder that holds components including a Navbar and Footer as well as a general Layout component that wraps all the pages.

What you'll get (a fully formatted page with a responsive navigation bar and footer)

Here's the site this template will start off with.



Dependencies Included







  1. Start a new Next project following this template with your choice of package manager (yarn/npm/pnpm(recommended)).

    pnpm create next-app YOURPROJECTNAME -e

    npm create next-app YOURPROJECTNAME -e

    yarn create next-app YOURPROJECTNAME -e

  2. Install dependencies.

    pnpm install

  3. Change placeholder strings. If you CRTL-F "INSERT" you should see all the string that should be changed.

    Should be changed to ⤵️
    List of strings to change/remove: **INSERT_APP_NAME** (2x), **INSERT_PAGE_NAME** (4x), **INSERT_PAGE_PATH** (4x) in components/layout
  4. Delete the INSERTPAGEPATH.tsx page or use it as a Page template and your project should be ready for your own code!