nuxt-starter Tailwind Templates

Nuxt Starter

Little script to help create nuxt boilerplate with tailwind css

šŸš€ Nuxt 3 Project Setup Script

This Bash script automates the setup of a Nuxt 3 project with Tailwind CSS and Pinia state management.
It ensures the required tools are installed, asks for user preferences, and sets up everything automatically.

šŸ› ļø Features

āœ… Checks if npm and pnpm are installed (installs pnpm if missing)
āœ… Asks for the project name (default: my-nuxt-app)
āœ… Option to create the project in the current directory or a new folder
āœ… Lets you choose between pnpm or npm as the package manager
āœ… Installs Nuxt 3, Tailwind CSS, and Pinia
āœ… Configures Tailwind CSS & Nuxt settings automatically

šŸ“„ Installation & Usage

1ļøāƒ£ Download & Make Executable

git clone https://github.com/astratow/nuxt-starter.git
cd nuxt-starter
chmod +x start-nuxt.sh

2ļøāƒ£ Run the Script

./start-nuxt.sh

šŸ”§ What the Script Does

1ļøāƒ£ Asks for the project name (default: window-quote-app)

2ļøāƒ£ Asks if you want to create the project in the current directory

3ļøāƒ£ Checks & installs pnpm if missing

4ļøāƒ£ Lets you choose between pnpm or npm

5ļøāƒ£ Runs nuxi init to create the Nuxt 3 project

6ļøāƒ£ Installs dependencies (Nuxt 3, Tailwind CSS, Pinia)

7ļøāƒ£ Configures Tailwind CSS automatically

8ļøāƒ£ Sets up nuxt.config.ts with Tailwind & Pinia

šŸš€ Running the Project

Once setup is complete, run:

bash

pnpm run dev  # or npm run dev if chosen

This will start a development server on localhost:3000.

šŸ› ļø Troubleshooting

pnpm Not Found in Git Bash?

If pnpm is installed but not found in Git Bash, add it to your PATH:

bash

echo 'export PATH="$PATH:/c/Users/YourUser/AppData/Local/pnpm"' >> ~/.bashrc
source ~/.bashrc

Or enable corepack:

bash

corepack enable
corepack prepare pnpm@latest --activate

Top categories

Loading Svelte Themes