Better code split for faster pages + image compression

This commit is contained in:
Julien Nahum
2022-12-14 10:27:21 +01:00
parent cc0a656223
commit bd80cb58ec
48 changed files with 189 additions and 284 deletions

View File

@@ -30,8 +30,6 @@ import {mapState, mapActions} from 'vuex'
import QuickRegister from '../auth/components/QuickRegister'
import initForm from "../../mixins/form_editor/initForm"
const FormEditor = () => import('../../components/open/forms/components/FormEditor')
const loadTemplates = function () {
store.commit('open/templates/startLoading')
store.dispatch('open/templates/loadIfEmpty').then(() => {
@@ -43,7 +41,6 @@ export default {
name: 'CreateFormGuest',
mixins: [initForm],
components: {
FormEditor,
QuickRegister
},

View File

@@ -23,8 +23,6 @@ import Form from 'vform'
import {mapState, mapActions} from 'vuex'
import initForm from "../../mixins/form_editor/initForm";
const FormEditor = () => import('../../components/open/forms/components/FormEditor')
const loadTemplates = function () {
store.commit('open/templates/startLoading')
store.dispatch('open/templates/loadIfEmpty').then(() => {
@@ -36,9 +34,7 @@ export default {
name: 'CreateForm',
mixins: [initForm],
components: {
FormEditor,
},
components: {},
metaInfo() {
return {title: 'Create a new Form'}

View File

@@ -24,7 +24,6 @@ import Breadcrumb from '../../components/common/Breadcrumb'
import Form from 'vform'
import { mapState } from 'vuex'
const FormEditor = () => import('../../components/open/forms/components/FormEditor')
const loadForms = function () {
store.commit('open/forms/startLoading')
@@ -35,7 +34,7 @@ const loadForms = function () {
export default {
name: 'EditForm',
components: { Breadcrumb, FormEditor },
components: { Breadcrumb },
beforeRouteEnter (to, from, next) {
if (!store.getters['open/forms/getBySlug'](to.params.slug)) {