1
0
Fork 1
mirror of https://github.com/pixelfed/pixelfed.git synced 2024-12-28 10:46:49 +00:00
pixelfed/resources/assets/js/app.js

21 lines
624 B
JavaScript
Raw Normal View History

2019-07-27 03:29:05 +00:00
window._ = require('lodash');
window.Popper = require('popper.js').default;
window.pixelfed = window.pixelfed || {};
window.$ = window.jQuery = require('jquery');
require('bootstrap');
window.axios = require('axios');
window.axios.defaults.headers.common['X-Requested-With'] = 'XMLHttpRequest';
require('readmore-js');
let token = document.head.querySelector('meta[name="csrf-token"]');
if (token) {
window.axios.defaults.headers.common['X-CSRF-TOKEN'] = token.content;
} else {
2019-08-02 04:39:50 +00:00
console.error('CSRF token not found.');
2019-07-27 03:29:05 +00:00
}
2019-08-02 04:39:50 +00:00
2019-08-02 08:14:30 +00:00
window.App = window.App || {};
2019-08-02 04:39:50 +00:00
window.App.boot = function() {
new Vue({ el: '#content'});
}