Commit 0cdcc779 authored by Michael Zhang's avatar Michael Zhang

Make axios automatically send the `X-CSRF-TOKEN`

parent d0c5c041
......@@ -28,6 +28,7 @@ window.Vue = require('vue');
window.axios = require('axios');
window.axios.defaults.headers.common = {
'X-CSRF-TOKEN': window.Laravel.csrfToken,
'X-Requested-With': 'XMLHttpRequest'
};
......
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