JSON now comes from external file

This commit is contained in:
Alicia Sykes
2019-07-21 21:33:26 +01:00
parent c4bd506966
commit 9a57f0aeab
4 changed files with 89 additions and 3 deletions

View File

@@ -3,7 +3,7 @@
<h1>{{title}}</h1>
<span class="subtitle">{{subtitle}}</span>
<div class="item-group-container">
<ItemGroup title="Server Management"/>
<ItemGroup v-for="item in items" :key="item.id" :title="item.name"/>
<ItemGroup title="External Infrastructure"/>
<ItemGroup title="Utilities"/>
</div>
@@ -13,12 +13,18 @@
<script>
import ItemGroup from '@/components/ItemGroup.vue'
import * as linkData from './../data/item-data.json'
export default {
name: 'home',
components: {
ItemGroup
},
data: () => {
return {
items: linkData.default
}
},
props: {
title: { default: 'Panel', type: String },
subtitle: { default: 'All your server management tools in one place', type: String }