This repository provides a boilerplate for a web application built using Laravel 11, Inertia.js with Vue 3, TypeScript, and shadcn/ui. It includes a devcontainer setup, husky pre-commit hooks, lint-staged, ESLint, and Prettier.
- Laravel 11: A PHP framework for web artisans.
- Inertia.js with Vue 3: A framework that lets you quickly build modern single-page React, Vue and Svelte apps using classic server-side routing and controllers.
- TypeScript: A statically typed superset of JavaScript that adds optional types.
- shadcn/ui: A UI library for Vue.js (assuming it's a UI library).
- Devcontainer: A development container for Visual Studio Code, providing a fully configured development environment that can be shared across a team.
- Husky pre-commit hooks: A tool to facilitate running tasks on Git hooks, like pre-commit.
- Lint-staged: A package that allows you to run linters on staged files.
- ESLint: A pluggable and configurable linter tool for identifying and reporting on patterns in JavaScript.
- Prettier: An opinionated code formatter that enforces a consistent style by parsing your code and re-printing it.
These instructions will get you a copy of the boilerplate up and running on your local machine for development and testing purposes.
- Docker
- Visual Studio Code with Remote - Containers extension
- Clone the repository
git clone https://github.com/xqsit94/laravel-vue3-shadcn.git
-
Open the project folder in Visual Studio Code.
-
When prompted to "Reopen in Container", click "Reopen in Container". This will start the build of the Docker container defined in the
.devcontainer
folder. -
Once the build is complete, you'll automatically be connected to the container. All commands from here are run inside the container.
-
Install PHP dependencies
sail composer install
- Install JavaScript dependencies
bun install
- Copy .env.example and create a .env file
cp .env.example .env
- Generate a new application key
sail php artisan key:generate
- Run the database migrations (Set the database connection in .env before migrating)
sail php artisan migrate
- Run the application in development mode
bun run dev