Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
103 commits
Select commit Hold shift + click to select a range
6e092c3
Upgrading to Inertia 2 and Tailwind v4
Dec 12, 2024
d9cf563
Adding functionality for login, register, and viewing dashboard
Dec 13, 2024
1d787b4
updating correct .env with creds
Dec 13, 2024
e39f567
Adding updated readme
Dec 13, 2024
55f55fb
downgrading back to Tailwind v3 until official release is out
tnylea Dec 30, 2024
b3d9edf
Adding shadcn library back
tnylea Dec 30, 2024
511b380
porting over more auth functionality and controllers
tnylea Jan 2, 2025
58d6ad0
Adding feature parity match with the react starter kit
tnylea Jan 2, 2025
02f8cd2
Getting tests to pass
tnylea Jan 2, 2025
5cb6158
renaming to capital Components and updating Readme
tnylea Jan 2, 2025
15c8305
Updating CamcelCase for password constants
tnylea Jan 2, 2025
aa38161
restructure files/folders in js folder
tnylea Jan 2, 2025
679a013
Adding updates to vue js folder
tnylea Jan 2, 2025
6d6f974
Adding name updates
tnylea Jan 2, 2025
bc96ec0
Adding name updates
tnylea Jan 2, 2025
64a906b
Adding name updates
tnylea Jan 2, 2025
71577e7
fixing builds
tnylea Jan 3, 2025
4541a0e
Adding readme info for Vue Starter Kit
tnylea Jan 3, 2025
b2d7cee
Adding update to readme
tnylea Jan 3, 2025
a2654a8
updating the file structur
tnylea Jan 3, 2025
6d8ec73
cleanup of vue starter kit
tnylea Jan 6, 2025
bfe28f4
Adding some cleanup and tasks to improve
tnylea Jan 6, 2025
e84cf7b
Adding updated styles to delete section
tnylea Jan 7, 2025
718db16
adding updates to remove all red squigglies from source files
tnylea Jan 7, 2025
113a573
removing unneccessary field in tsconfig
tnylea Jan 7, 2025
e3eb237
cleanup and fixing light/dark mode on load
tnylea Jan 7, 2025
1058209
Adding husky pre-commit
tnylea Jan 7, 2025
b825fb5
Testing husky
tnylea Jan 7, 2025
e6c3b33
Adding husky to package json
tnylea Jan 7, 2025
b13a146
Adding improvements and fixes
tnylea Jan 10, 2025
db3665f
cleaning up and documentating
tnylea Jan 13, 2025
9e28d02
Removing unneccessary lines and casing
tnylea Jan 13, 2025
36c8ab0
updating appearance changes
tnylea Jan 13, 2025
1e3c940
Adding more packages and prettier file
tnylea Jan 13, 2025
1ee7724
Ading lint commands
tnylea Jan 13, 2025
5a01092
Adding linted files
tnylea Jan 13, 2025
c6fff86
cleaning up layout file
tnylea Jan 13, 2025
8c01c15
adding linted files and updating heading component
tnylea Jan 15, 2025
2b9b487
re-organizing settings layout file
tnylea Jan 15, 2025
42b1911
making design changes
tnylea Jan 15, 2025
3d92862
Adding latest UI updates
tnylea Jan 16, 2025
e9ce8df
making copy and structure updates
tnylea Jan 16, 2025
4947a7a
changing to minimum stability dev
tnylea Jan 27, 2025
010885b
updating the name in composer json
tnylea Jan 27, 2025
729f49d
cleaning up structure similar to react starter kit
tnylea Jan 28, 2025
a38b786
fixing some typescript errors
tnylea Jan 28, 2025
9eef6b3
wip
taylorotwell Jan 31, 2025
6ac26e8
fixing the header layout
tnylea Jan 31, 2025
e6ad843
Merge branch 'develop' of https://github.com/laravel/vue-starter-kit …
tnylea Jan 31, 2025
8aeaaef
cleaning up a bit more and fixing UI
tnylea Jan 31, 2025
fc703fa
Updating the password reset functionality for security
tnylea Feb 6, 2025
d0e5aff
updating password reset
tnylea Feb 6, 2025
f894fb0
removing husky from the Vue starter kit and implementing the new esli…
tnylea Feb 6, 2025
fa13dee
Adding updates to actions and code styles
tnylea Feb 6, 2025
1e2b5a4
Adding eslint config and eslint fixes
tnylea Feb 6, 2025
dd8399b
Adding original content back in ui folder
tnylea Feb 6, 2025
66d1394
putting files back from inside the ui folder
tnylea Feb 6, 2025
faed682
fixing the formatting in eslint
tnylea Feb 6, 2025
6712f3a
Adding a few directories to the prettierignore file so prettier does …
tnylea Feb 6, 2025
4d913b6
Adding the default PHP stan file
tnylea Feb 6, 2025
6942886
updating the email verify controller to pass phpstan
tnylea Feb 6, 2025
cb9902b
Merge pull request #2 from laravel/actions-updates
tnylea Feb 6, 2025
a3db524
cleanup
tnylea Feb 6, 2025
48351b6
Merge branch 'develop' of https://github.com/laravel/vue-starter-kit …
tnylea Feb 6, 2025
b0c4c4a
updating action versions
tnylea Feb 6, 2025
daec0e1
Adding remember me checkbox option
tnylea Feb 10, 2025
22daa17
formatting
taylorotwell Feb 10, 2025
3e632dc
uncomment remember me
taylorotwell Feb 10, 2025
184d81e
formatting
taylorotwell Feb 10, 2025
06a9717
pint
taylorotwell Feb 10, 2025
6aaf044
Adding flex col to container shell
tnylea Feb 10, 2025
7ab9f8f
Merge branch 'develop' into taylors-version
taylorotwell Feb 10, 2025
e075628
Adding fix for the Vue sidebar
tnylea Feb 10, 2025
9ae68ba
Merge branch 'develop' into taylors-version
taylorotwell Feb 10, 2025
d97b556
formatting
taylorotwell Feb 10, 2025
ff7eb21
wip
taylorotwell Feb 10, 2025
ccc6df3
wip
taylorotwell Feb 10, 2025
17c7a0c
wip
taylorotwell Feb 10, 2025
ee01743
wip
taylorotwell Feb 10, 2025
c634e39
wip
taylorotwell Feb 10, 2025
958eaaa
formatting
taylorotwell Feb 10, 2025
6418f11
wip
taylorotwell Feb 10, 2025
492df24
Removing files from breeze
tnylea Feb 10, 2025
6071b0f
Getting tests to pass with files removed
tnylea Feb 11, 2025
be781ae
clearing npm cache
tnylea Feb 11, 2025
ca1debd
fixing capitalization
tnylea Feb 11, 2025
d18dc64
Adding some updates to fix testsg
tnylea Feb 11, 2025
ae62a58
Adding the defineProps directly
tnylea Feb 11, 2025
c65a6bb
Merge pull request #3 from laravel/fileCleanUp
tnylea Feb 11, 2025
6419173
Adding fix to password validation
tnylea Feb 11, 2025
5dc1848
Merge pull request #4 from laravel/fixPasswordUpdateError
tnylea Feb 11, 2025
1280fb4
allowing linter write access
tnylea Feb 11, 2025
17df482
Merge pull request #5 from laravel/updateLinter
tnylea Feb 11, 2025
625fd7e
wip
taylorotwell Feb 11, 2025
01757ca
add redis persistent
taylorotwell Feb 11, 2025
d511877
moving to PHPUnit tests
tnylea Feb 11, 2025
612bf00
Adding phpunit tests in tests.yml
tnylea Feb 11, 2025
13d03e5
Merge pull request #6 from laravel/usePHPUNIT
tnylea Feb 11, 2025
ee2fcc8
Adding the default Pest php file back
tnylea Feb 12, 2025
3b65ce7
font
taylorotwell Feb 12, 2025
688d2e7
Adding updates to prettier functionality
tnylea Feb 13, 2025
0bb151b
Update .prettierignore
taylorotwell Feb 13, 2025
d5f78a3
Merge pull request #7 from laravel/prettierUpdates
taylorotwell Feb 13, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,5 @@
*.md diff=markdown
*.php diff=php

/.github export-ignore
CHANGELOG.md export-ignore
.styleci.yml export-ignore
README.md export-ignore
49 changes: 49 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: linter

on:
push:
branches:
- develop
- main
pull_request:
branches:
- develop
- main

permissions:
contents: write

jobs:
quality:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.4'

- name: Install Dependencies
run: |
composer install -q --no-ansi --no-interaction --no-scripts --no-progress --prefer-dist
npm install

- name: Run Pint
run: vendor/bin/pint

- name: Frontend Format Check
run: npm run format

- name: Frontend Lint
run: npm run lint

- name: Commit Changes
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: fix code style
commit_options: '--no-verify'

# We need to run PHPStan after commiting changes as it does not auto-fix errors...
- name: PHPStan
run: ./vendor/bin/phpstan
56 changes: 56 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
name: tests

on:
push:
branches:
- develop
- main
pull_request:
branches:
- develop
- main

jobs:
ci:
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: 8.4
tools: composer:v2
coverage: xdebug

- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'npm'

- name: Install Node Dependencies
run: npm ci

- name: Create SQLite Database
run: touch database/database.sqlite

- name: Install Dependencies
run: composer install --no-interaction --prefer-dist --optimize-autoloader

- name: Copy Environment File
run: cp .env.example .env

- name: Generate Application Key
run: php artisan key:generate

- name: Publish Ziggy Configuration
run: php artisan ziggy:generate

- name: Build Assets
run: npm run build

- name: Tests
run: ./vendor/bin/phpunit
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@
/storage/*.key
/storage/pail
/vendor
.DS_Store
.env
.env.backup
.env.production
.phpactor.json
.phpunit.result.cache
.windsurfrules
Homestead.json
Homestead.yaml
auth.json
Expand Down
1 change: 1 addition & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
resources/js/components/ui/*
18 changes: 18 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"semi": true,
"singleQuote": true,
"singleAttributePerLine": false,
"htmlWhitespaceSensitivity": "css",
"printWidth": 150,
"plugins": ["prettier-plugin-organize-imports", "prettier-plugin-tailwindcss"],
"tailwindFunctions": ["clsx", "cn"],
"tabWidth": 4,
"overrides": [
{
"files": "**/*.yml",
"options": {
"tabWidth": 2
}
}
]
}
108 changes: 66 additions & 42 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,66 +1,90 @@
<p align="center"><a href="https://laravel.com" target="_blank"><img src="https://raw.githubusercontent.com/laravel/art/master/logo-lockup/5%20SVG/2%20CMYK/1%20Full%20Color/laravel-logolockup-cmyk-red.svg" width="400" alt="Laravel Logo"></a></p>
<p align="center"><a href="https://laravel.com" target="_blank"><img src="https://cdn.devdojo.com/assets/svg/laravel-vue-logo.svg" width="300" alt="Laravel Logo"></a></p>

<p align="center">
<a href="https://github.com/laravel/framework/actions"><img src="https://github.com/laravel/framework/workflows/tests/badge.svg" alt="Build Status"></a>
<a href="https://packagist.org/packages/laravel/framework"><img src="https://img.shields.io/packagist/dt/laravel/framework" alt="Total Downloads"></a>
<a href="https://packagist.org/packages/laravel/framework"><img src="https://img.shields.io/packagist/v/laravel/framework" alt="Latest Stable Version"></a>
<a href="https://github.com/laravel/vue-starter-kit/actions"><img src="https://github.com/laravel/vue-starter-kit/workflows/tests/badge.svg" alt="Build Status"></a>
<a href="https://packagist.org/packages/laravel/framework"><img src="https://img.shields.io/packagist/l/laravel/framework" alt="License"></a>
</p>

## About Laravel
<img src="https://cdn.devdojo.com/images/december2024/screenshot.png" />

Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experience to be truly fulfilling. Laravel takes the pain out of development by easing common tasks used in many web projects, such as:
## Introduction

- [Simple, fast routing engine](https://laravel.com/docs/routing).
- [Powerful dependency injection container](https://laravel.com/docs/container).
- Multiple back-ends for [session](https://laravel.com/docs/session) and [cache](https://laravel.com/docs/cache) storage.
- Expressive, intuitive [database ORM](https://laravel.com/docs/eloquent).
- Database agnostic [schema migrations](https://laravel.com/docs/migrations).
- [Robust background job processing](https://laravel.com/docs/queues).
- [Real-time event broadcasting](https://laravel.com/docs/broadcasting).
Welcome to the Laravel **Vue Starter Kit**, a starter kit built using [Laravel](https://laravel.com), [Vue](https://vuejs.org), [Inertia](https://inertiajs.com), and [Tailwind CSS](https://tailwindcss.com).

Laravel is accessible, powerful, and provides tools required for large, robust applications.
## Installation

## Learning Laravel
To install the starter kit, run the following command:

Laravel has the most extensive and thorough [documentation](https://laravel.com/docs) and video tutorial library of all modern web application frameworks, making it a breeze to get started with the framework.
1. git clone https://github.com/laravel/vue-starter-kit
2. cd vue-starter-kit
3. git checkout develop
4. copy .env.example .env
5. install dependencies `npm install && composer install`
6. run migrations `php artisan migrate`
7. add encryption key `php artisan key:generate`
8. start the asset watcher `npm run dev`

You may also try the [Laravel Bootcamp](https://bootcamp.laravel.com), where you will be guided through building a modern Laravel application from scratch.
Visit the URL for your app and you're good to go!

If you don't feel like reading, [Laracasts](https://laracasts.com) can help. Laracasts contains thousands of video tutorials on a range of topics including Laravel, modern PHP, unit testing, and JavaScript. Boost your skills by digging into our comprehensive video library.
## Features

## Laravel Sponsors
This Starter Kit includes the following features:

We would like to extend our thanks to the following sponsors for funding Laravel development. If you are interested in becoming a sponsor, please visit the [Laravel Partners program](https://partners.laravel.com).
- **User Authentication** (login, register, password reset, email verify, and password confirmation)
- **Dashboard Page** (Auth Protected User Dashboard Page)
- **Settings Page** (Profile Update/Delete, Password Update, Appearance)

### Premium Partners
## Front-end App Structure

- **[Vehikl](https://vehikl.com/)**
- **[Tighten Co.](https://tighten.co)**
- **[WebReinvent](https://webreinvent.com/)**
- **[Kirschbaum Development Group](https://kirschbaumdevelopment.com)**
- **[64 Robots](https://64robots.com)**
- **[Curotec](https://www.curotec.com/services/technologies/laravel/)**
- **[Cyber-Duck](https://cyber-duck.co.uk)**
- **[DevSquad](https://devsquad.com/hire-laravel-developers)**
- **[Jump24](https://jump24.co.uk)**
- **[Redberry](https://redberry.international/laravel/)**
- **[Active Logic](https://activelogic.com)**
- **[byte5](https://byte5.de)**
- **[OP.GG](https://op.gg)**
The majority of the front-end code is located in the `resources/js` folder. We follow Vue.js best practices and conventions for organizing these files and folders. The structure follows these naming conventions:

## Contributing
**Folders**: Use kebab-case

Thank you for considering contributing to the Laravel framework! The contribution guide can be found in the [Laravel documentation](https://laravel.com/docs/contributions).
```
resources/js/
├── components/ # Reusable Vue components
├── composables/ # Vue composables/hooks
├── layouts/ # Application layouts
├── lib/ # Utility functions and configurations
├── pages/ # Page components
└── types/ # Typescript definitions and interfaces
```

## Code of Conduct
**Components**: Use PascalCase for component files

In order to ensure that the Laravel community is welcoming to all, please review and abide by the [Code of Conduct](https://laravel.com/docs/contributions#code-of-conduct).
```
components/
└── AppearanceTabs.vue
└── NavigationBar.vue
```

## Security Vulnerabilities
**Composables/Utilities**: Use camelCase for utility files and composables

If you discover a security vulnerability within Laravel, please send an e-mail to Taylor Otwell via [[email protected]](mailto:[email protected]). All security vulnerabilities will be promptly addressed.
```
composables/
└── useAuth.ts
└── useSettings.ts
```

## License
This structure aligns more with the default Vue conventions.

The Laravel framework is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).
## Icons

This starter kit leverages the [Lucide Vue Library](https://lucide.dev/guide/packages/lucide-vue-next), which provides you with a collection of over 1000 icons. View the full list of icons [here](https://lucide.dev/icons).

Here's a quick example of using an icon in one of your Vue Components:

```
<script setup lang="ts">
...
import { Rocket } from 'lucide-vue-next';
...
</script>

<template>
<p class="flex items-center space-x-2">
<Rocket />
<span class="text-lg font-medium">Vue Starter Kit</span>
</p>
</template>
```
51 changes: 51 additions & 0 deletions app/Http/Controllers/Auth/AuthenticatedSessionController.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
<?php

namespace App\Http\Controllers\Auth;

use App\Http\Controllers\Controller;
use App\Http\Requests\Auth\LoginRequest;
use Illuminate\Http\RedirectResponse;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Route;
use Inertia\Inertia;
use Inertia\Response;

class AuthenticatedSessionController extends Controller
{
/**
* Show the login page.
*/
public function create(Request $request): Response
{
return Inertia::render('auth/Login', [
'canResetPassword' => Route::has('password.request'),
'status' => $request->session()->get('status'),
]);
}

/**
* Handle an incoming authentication request.
*/
public function store(LoginRequest $request): RedirectResponse
{
$request->authenticate();

$request->session()->regenerate();

return redirect()->intended(route('dashboard', absolute: false));
}

/**
* Destroy an authenticated session.
*/
public function destroy(Request $request): RedirectResponse
{
Auth::guard('web')->logout();

$request->session()->invalidate();
$request->session()->regenerateToken();

return redirect('/');
}
}
41 changes: 41 additions & 0 deletions app/Http/Controllers/Auth/ConfirmablePasswordController.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<?php

namespace App\Http\Controllers\Auth;

use App\Http\Controllers\Controller;
use Illuminate\Http\RedirectResponse;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use Illuminate\Validation\ValidationException;
use Inertia\Inertia;
use Inertia\Response;

class ConfirmablePasswordController extends Controller
{
/**
* Show the confirm password page.
*/
public function show(): Response
{
return Inertia::render('auth/ConfirmPassword');
}

/**
* Confirm the user's password.
*/
public function store(Request $request): RedirectResponse
{
if (! Auth::guard('web')->validate([
'email' => $request->user()->email,
'password' => $request->password,
])) {
throw ValidationException::withMessages([
'password' => __('auth.password'),
]);
}

$request->session()->put('auth.password_confirmed_at', time());

return redirect()->intended(route('dashboard', absolute: false));
}
}
Loading
Loading