You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: UPGRADE.md
+21Lines changed: 21 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,14 @@
4
4
5
5
> **Note** This upgrade guide does not cover all possible Mix use cases, such as Sass compilation. Please consult the [Vite documentation](https://vitejs.dev/guide/) for information on configuring Vite for these scenarios.
6
6
7
+
### Update Laravel Framework
8
+
9
+
To make use of the new Vite integration, you will need to update to at least version `9.19.0` of the `laravel/framework`:
10
+
11
+
```sh
12
+
composer require laravel/framework:^9.19.0
13
+
```
14
+
7
15
### Install Vite and the Laravel Plugin
8
16
9
17
First, you will need to install [Vite](https://vitejs.dev/) and the [Laravel Vite Plugin](https://www.npmjs.com/package/laravel-vite-plugin) using your npm package manager of choice:
@@ -119,6 +127,12 @@ The following function can be used instead:
119
127
});
120
128
```
121
129
130
+
Additionally, you should ensure you have updated to at least version `0.6.3` of the `inertia-laravel` package:
131
+
132
+
```sh
133
+
composer require inertiajs/inertia-laravel:^0.6.3
134
+
```
135
+
122
136
### Update environment variables
123
137
124
138
You will need to update the environment variables that are explicitly exposed in your `.env` files and in hosting environments such as Forge to use the `VITE_` prefix instead of `MIX_`:
@@ -330,6 +344,13 @@ npm run build
330
344
331
345
For further information on how to use Vite, please check out [the Laravel Vite documentation](https://laravel.com/docs/vite).
332
346
347
+
### Troubleshooting
348
+
349
+
If you have followed the upgrade guide, but are still having issues you should try the following steps:
350
+
351
+
- Run `php artisan view:clear` to clear any compiled view assets.
352
+
- If your development web server is running on HTTPS, check out the ["Working With A Secure Development Server"](https://laravel.com/docs/9.x/vite#working-with-a-secure-development-server) section of the documentation.
0 commit comments