Browse Source

Vue Nachrichtenfeld-Komponente erstellt (korrigiert)

pull/1/head
Edwina Barbalan 6 years ago
parent
commit
4eeb3d003b
2 changed files with 4 additions and 5 deletions
  1. 3
    4
      public/home.js
  2. 1
    1
      public/index.html

+ 3
- 4
public/home.js View File

@@ -1,6 +1,5 @@
Vue.component('msg-item', {
template: `<div id="newmessages-example">
<div class="om-card card">
template: `<div class="om-card card">
<h6 class="msg-head">
<b>{{ title }}</b>
<img src="favicon.ico" width=20px height=20px>
@@ -10,12 +9,12 @@ Vue.component('msg-item', {
<div class="om-user-line">
<i class="material-icons">account_circle</i>
Erstellt von {{ user }}
</div></div>`,
</div>`,
props: ['title', 'subject', 'tag', 'user']
})

new Vue({
el: '#mewmessages-example',
el: '#newmessages-example',
data: {
messages: [
{

+ 1
- 1
public/index.html View File

@@ -36,7 +36,7 @@

<script src="https://unpkg.com/vue"></script>
<div class="om-content">
<div id="mewmessages-example">
<div id="newmessages-example">
<div
is="msg-item"
v-for="(msg, index) in messages"

Loading…
Cancel
Save