when you submit a standard form and the csrf middleware is enabled, you have to include the csrf token as a hidden input field. When submitting data via the vue-router, you need to include it in the request header using the above code.
meta id="token" name="token" value="{ {csrf_token() }}"
in the head ?
And add the line you suggest in the begining in the main.js?
Because i can not insert the php code directly in the js file
Would you like to give a instance in detail