Skip to content

Commit

Permalink
remove keep-alive from root component
Browse files Browse the repository at this point in the history
  • Loading branch information
TeodoraPavlova committed Feb 1, 2024
1 parent 11d38ef commit 12701eb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 15 deletions.
9 changes: 2 additions & 7 deletions frontend/src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,7 @@
<AlertDisplay/>
<div class="container mt-2">
<router-view v-slot="{Component}">
<keep-alive :exclude="nonCachedRouteComponents">
<component :is="Component"/>
</keep-alive>
<component :is="Component"/>
</router-view>
</div>

Expand Down Expand Up @@ -82,10 +80,7 @@ export default {
console.warn("List of available schemas not ready, yet");
}
return _avail_schemas
},
nonCachedRouteComponents () {
return this.$router.options.routes.filter(route => !route.cached).map(route => route.component.name);
},
}
},
methods: {
onPendingReviews() {
Expand Down
8 changes: 0 additions & 8 deletions frontend/src/router.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ export const router = createRouter({
path: '/createSchema',
component: SchemaCreate,
name: 'schema-new',
cached: true,
meta: {
title: 'Create Schema'
}
Expand All @@ -24,7 +23,6 @@ export const router = createRouter({
path: '/bulkEdit/:schemaSlug',
component: EntityBulkEdit,
name: 'bulk-edit',
cached: true,
meta: {
title: "Edit Schemas"
}
Expand All @@ -33,7 +31,6 @@ export const router = createRouter({
path: '/schema/:schemaSlug',
component: Schema,
name: 'schema-view',
cached: true,
meta: {
title: 'Schema Details'
}
Expand All @@ -42,7 +39,6 @@ export const router = createRouter({
path: '/schema/:schemaSlug/:entitySlug',
component: Entity,
name: 'entity-view',
cached: false,
meta: {
title: 'Entity Details'
}
Expand All @@ -51,15 +47,13 @@ export const router = createRouter({
path: '/review',
component: Changes,
name: 'review-list',
cached: true,
meta: {
title: 'Pending Reviews'
}
},
{
path: '/user-management',
component: AuthManager,
cached: true,
name: 'auth-manager',
meta: {
title: 'User Management'
Expand All @@ -69,7 +63,6 @@ export const router = createRouter({
path: '/',
component: SchemaList,
name: 'schema-list',
cached: true,
meta: {
title: 'All Schemas'
}
Expand All @@ -78,7 +71,6 @@ export const router = createRouter({
path: '/help/about',
component: About,
name: 'help-about',
cached: true,
meta: {
title: 'About AIMAAS'
}
Expand Down

0 comments on commit 12701eb

Please sign in to comment.