mirror of
https://github.com/lingble/chatwoot.git
synced 2025-12-23 22:27:03 +00:00
45 lines
1.3 KiB
JavaScript
45 lines
1.3 KiB
JavaScript
import { createApp } from 'vue';
|
|
|
|
import '../dashboard/assets/scss/app.scss';
|
|
import 'vue-multiselect/dist/vue-multiselect.css';
|
|
import 'floating-vue/dist/style.css';
|
|
// import tailwindStyles from '../dashboard/assets/scss/_woot.scss?inline';
|
|
|
|
import VueDOMPurifyHTML from 'vue-dompurify-html';
|
|
import { domPurifyConfig } from '../shared/helpers/HTMLSanitizer.js';
|
|
|
|
import store from '../dashboard/store';
|
|
import constants from '../dashboard/constants/globals';
|
|
import axios from 'axios';
|
|
import createAxios from '../ui/axios';
|
|
import commonHelpers from '../dashboard/helper/commons';
|
|
import vueActionCable from '../dashboard/helper/actionCable';
|
|
|
|
import MessageList from '../ui/MessageList.vue';
|
|
import i18nMessages from '../dashboard/i18n';
|
|
import { createI18n } from 'vue-i18n';
|
|
|
|
const i18n = createI18n({
|
|
legacy: false,
|
|
locale: 'en',
|
|
messages: i18nMessages,
|
|
});
|
|
|
|
commonHelpers();
|
|
// eslint-disable-next-line no-underscore-dangle
|
|
window.__CHATWOOT_STORE__ = store;
|
|
window.WootConstants = constants;
|
|
window.axios = createAxios(axios);
|
|
|
|
store.dispatch('setUser').then(() => {
|
|
const app = createApp(MessageList);
|
|
|
|
app.use(store);
|
|
app.use(i18n);
|
|
app.use(VueDOMPurifyHTML, domPurifyConfig);
|
|
// eslint-disable-next-line no-underscore-dangle
|
|
vueActionCable.init(store, window.__PUBSUB_TOKEN__);
|
|
|
|
app.mount('#app');
|
|
});
|