Commit 9c027827 authored by Taylor Otwell's avatar Taylor Otwell

simplify csrf token retrieval. remove package.

parent e6cc6034
window._ = require('lodash');
window.Cookies = require('js-cookie');
/**
* We'll load jQuery and the Bootstrap jQuery plugin which provides support
......@@ -27,7 +26,7 @@ require('vue-resource');
*/
Vue.http.interceptors.push(function (request, next) {
request.headers['X-XSRF-TOKEN'] = Cookies.get('XSRF-TOKEN');
request.headers['X-XSRF-TOKEN'] = Laravel.csrfToken;
next();
});
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment