Tools
Cross out the bad line
Paste the instructions you wrote. This page crosses out a line the guides forbid. Copy what is left.
This page does not chat. Paste the instructions you wrote for your editor. One line each. To practice first, catch the bad line.
Paste the instructions. One line each.
With JavaScript off, the box does not cross anything out. These are the lines it crosses out.
- Ziggy or Wayfinder for Laravel routes in Vue. Do not install Ziggy on the Vue starter kit. You would have two ways to build the same URL.
- Typed Laravel routes in Vue with Wayfinder. Wayfinder is not Vue Router. Inertia still navigates.
- Deploy a Laravel and Vue app. If public/hot is on the server, every page loads JavaScript from the laptop. Do not commit it.
- Read an Inertia 409 after deploy. Do not abort(409) from a controller to mean this record changed. Inertia already uses 409 for the asset version.
- Turn on CORS credentials for a separate Vue app. Do not set allowed_origins to ['*'] in the same file as supports_credentials => true.
- Fix a 419 after you deploy. Do not disable VerifyCsrfToken for the whole web group. The token is the check.
- queue:work in production, listen locally. Do not call queue:work from a controller so a Vue button starts the worker. The button dispatches a job.
- Breeze, Jetstream, and the Vue starter kit. Do not install Breeze or Jetstream on the Vue starter kit. You would get two login stacks.
- Deploy a Laravel and Vue app. Do not add storage:link to a Cloud deploy. The disk resets on every deploy, so the symlink does not survive.
- Laravel and Vue pagination. Two rows with the same published_at do not give the cursor a stable bound, so order by id.
- Show a saved message in Vue. Do not register a second router.on('flash'). The Vue starter kit already listens.
- Queue a broadcast instead of blocking the save. Do not listen with useEcho on a public channel.
- Render simplePaginate without a last page. simplePaginate omits last_page. Do not compute page 2 of undefined.
- Trust proxies so HTTPS sticks. Do not call trustProxies(at: '*') on a machine exposed directly.
- When to use Pinia with Laravel and Inertia. Do not router.reload into a Pinia store so every component can read it. Pass the prop.
- Install Laravel Boost on a Vue starter kit. Do not install Boost inside the Vue app with npm. There is no Boost component to mount.
- Upload files from Vue to Laravel with Inertia. PHP does not fill a file on a real PUT, PATCH, or DELETE. Post the form and send _method of put.
- Keep soft-deleted rows off a Vue index. Do not call forceDelete() from the button you labeled Delete. That removes the row. Soft delete is the one you can restore.
- preserveState keeps the Vue page you have. Do not set preserveState: true on a logout request. The old page's props, including the user, stay on screen until something else navigates.
- Run migrations in the release, not in a request. Do not call Artisan::call('migrate') from a controller the Vue page can hit. Two deploys, or two curious browsers, should not race that.
- Install Telescope for local debugging. Do not return true for every user so a Vue admin link can open Telescope. Leave the viewTelescope gate on local.
- Keep the Inertia SSR process running. Do not read window in setup.