[Vuejs]-Get 419 error when posting from axios to laravel

3👍

Try this, it works for me so far but you’ll be without CSRF, go to ‘App\Http\Middleware\VerifyCsrfToken’ then edit the protected variable to this

 protected $except = [
     "/*"
 ];

the '/*' says to exclude CSRF from all routes, although this isn’t ideal it should fix the problem, Maybe just exclude those specific routes that are throwing you the error?

e.g. "/specificRoute"

Leave a comment