[mod] vuetify
This commit is contained in:
parent
3411ef7c9f
commit
e619617cde
3 changed files with 6 additions and 8 deletions
BIN
caddy/site/links/icon.png
Normal file
BIN
caddy/site/links/icon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 633 B |
|
@ -18,8 +18,9 @@
|
||||||
<li v-for="item in json"><a :href="item.href">{{ item.text }}</a></li>
|
<li v-for="item in json"><a :href="item.href">{{ item.text }}</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<button v-on:click="load">hits {{ hits }}</button>
|
<v-btn v-on:click="load">hits {{ hits }}</v-btn>
|
||||||
<div> {{ message }}</div>
|
<div> {{ message }}</div>
|
||||||
|
<iframe name="srv" src="icon.png" width="100%"></iframe>
|
||||||
</div>
|
</div>
|
||||||
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js" crossorigin="anonymous"></script>
|
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js" crossorigin="anonymous"></script>
|
||||||
<script src="//unpkg.com/vuetify@2.6.2/dist/vuetify.min.js" crossorigin="anonymous"></script>
|
<script src="//unpkg.com/vuetify@2.6.2/dist/vuetify.min.js" crossorigin="anonymous"></script>
|
||||||
|
|
|
@ -1,24 +1,21 @@
|
||||||
// app
|
// app
|
||||||
|
Vue.use(Vuetify);
|
||||||
var app = new Vue({
|
var app = new Vue({
|
||||||
el: '#app',
|
el: '#app',
|
||||||
data: {
|
data: {
|
||||||
message: 'Hello Vue!',
|
message: 'Hello Vue!',
|
||||||
json: null,
|
json: links,
|
||||||
hits:0,
|
hits:0,
|
||||||
loaded: null
|
loaded: null
|
||||||
},
|
},
|
||||||
filters: {
|
|
||||||
pretty: function(value) {
|
|
||||||
return JSON.stringify(JSON.parse(value), null, 2);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods:{
|
methods:{
|
||||||
load() {
|
load() {
|
||||||
this.loaded = new Date()
|
this.loaded = new Date()
|
||||||
this.hits += 1
|
this.hits += 1
|
||||||
fetch("links.json")
|
fetch("links.json")
|
||||||
.then(response => response.json())
|
.then(response => response.json())
|
||||||
.then(data => (this.json = data));
|
.then(data => (this.links = data));
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted () {
|
mounted () {
|
||||||
|
|
Loading…
Add table
Reference in a new issue