Blame view

examples/routers/time.vue 587 Bytes
7f9ea0dc   梁灏   init Time component
1
2
  <template>
      <div>
37086acc   梁灏   update Time
3
4
5
6
          <Time :time="time1" />
          <br>
          <Time :time="time2" />
          <br>
d2041471   梁灏   update Time
7
          <Time :time="time3" :interval="1" />
69a84401   梁灏   fix #4651
8
9
          <br>
          <Time :time="time4" />
7f9ea0dc   梁灏   init Time component
10
11
12
13
14
      </div>
  </template>
  <script>
      export default {
          data () {
eb37e68c   梁灏   update Time
15
              return {
d2041471   梁灏   update Time
16
                  time1: (new Date()).getTime() - 60 * 59 * 1000,
37086acc   梁灏   update Time
17
                  time2: (new Date()).getTime() - 86400 * 3 * 1000,
69a84401   梁灏   fix #4651
18
19
20
                  time3: (new Date()).getTime() - 1 * 1000,
                  time4: (new Date()).getTime() - 86400 * 60 * 1000,
              };
37086acc   梁灏   update Time
21
          }
69a84401   梁灏   fix #4651
22
      };
37086acc   梁灏   update Time
23
  </script>