File tree 3 files changed +64
-32
lines changed
3 files changed +64
-32
lines changed Original file line number Diff line number Diff line change 1
1
<template >
2
2
<div >
3
- <h2 >About</h2 >
4
- <p >hohoho</p >
3
+ <h2 >vue-hackernews-2.0</h2 >
4
+ <p >is a demo project built with the following technologies:</p >
5
+ <ul >
6
+ <li >Vue 2.0</li >
7
+ <li >vue-router 2.0</li >
8
+ <li >vuex 2.0</li >
9
+ <li >Webpack 2.0</li >
10
+ </ul >
11
+ <p >Check out <a href =" https://github.com/vuejs/vue/wiki/Vue-2.0-Beta---Starter-Resources" target =" _blank" >this guide</a > for getting started on Vue 2.0.</p >
12
+ <p >This project showcases these features:</p >
13
+ <ul >
14
+ <li >
15
+ Single file Vue components with:
16
+ <ul >
17
+ <li >Hot-reload during development</li >
18
+ <li >Stylus for CSS pre-processing</li >
19
+ <li >CSS extraction for production</li >
20
+ </ul >
21
+ </li >
22
+ <li >
23
+ Server-Side Rendering with:
24
+ <ul >
25
+ <li >Universal application code</li >
26
+ <li >Server-side data pre-fetching</li >
27
+ <li >Client-side DOM re-hydration</li >
28
+ </ul >
29
+ </li >
30
+ <li >Powerful yet easy-to-use animation system</li >
31
+ </ul >
32
+ <p ><a href =" https://github.com/vuejs/vue-hackernews-2.0" target =" _blank" >Source code on GitHub.</a ></p >
5
33
</div >
6
34
</template >
7
35
Original file line number Diff line number Diff line change 1
1
<template >
2
- <div class =" item-view" v-if =" item" >
3
- <div class =" item-view-header" >
4
- <a :href =" item.url" target =" _blank" >
5
- <h2 >{{ item.title }}</h2 >
6
- </a >
7
- <span v-if =" item.url" >({{ item.url | host }})</span >
8
- <p >
9
- {{ item.score }} points
10
- | by <router-link :to =" '/user/' + item.by" >{{ item.by }}</router-link >
11
- {{ item.time | timeAgo }} ago
12
- | {{ item.descendants }} comments
13
- </p >
14
- </div >
15
- <ul class =" item-view-comments" >
16
- <comment v-for =" id in item.kids" :id =" id" ></comment >
17
- </ul >
2
+ <div class =" item-view" >
3
+ <template v-if =" item " >
4
+ <div class =" item-view-header" >
5
+ <a :href =" item.url" target =" _blank" >
6
+ <h2 >{{ item.title }}</h2 >
7
+ </a >
8
+ <span v-if =" item.url" >({{ item.url | host }})</span >
9
+ <p >
10
+ {{ item.score }} points
11
+ | by <router-link :to =" '/user/' + item.by" >{{ item.by }}</router-link >
12
+ {{ item.time | timeAgo }} ago
13
+ | {{ item.descendants }} comments
14
+ </p >
15
+ </div >
16
+ <ul class =" item-view-comments" >
17
+ <comment v-for =" id in item.kids" :id =" id" ></comment >
18
+ </ul >
19
+ </template >
18
20
</div >
19
21
</template >
20
22
Original file line number Diff line number Diff line change 1
1
<template >
2
- <div class =" user-view" v-if =" user" >
3
- <ul >
4
- <li ><span class =" label" >user:</span > {{ user.id }}</li >
5
- <li ><span class =" label" >created:</span > {{ user.created | timeAgo }} ago</li >
6
- <li ><span class =" label" >karma:</span > {{user.karma}}</li >
7
- <li >
8
- <span class =" label" >about:</span >
9
- <div class =" about" v-html =" user.about" ></div >
10
- </li >
11
- </ul >
12
- <p class =" links" >
13
- <a :href =" 'https://news.ycombinator.com/submitted?id=' + user.id" >submissions</a ><br >
14
- <a :href =" 'https://news.ycombinator.com/threads?id=' + user.id" >comments</a >
15
- </p >
2
+ <div class =" user-view" >
3
+ <template v-if =" user " >
4
+ <ul >
5
+ <li ><span class =" label" >user:</span > {{ user.id }}</li >
6
+ <li ><span class =" label" >created:</span > {{ user.created | timeAgo }} ago</li >
7
+ <li ><span class =" label" >karma:</span > {{user.karma}}</li >
8
+ <li >
9
+ <span class =" label" >about:</span >
10
+ <div class =" about" v-html =" user.about" ></div >
11
+ </li >
12
+ </ul >
13
+ <p class =" links" >
14
+ <a :href =" 'https://news.ycombinator.com/submitted?id=' + user.id" >submissions</a ><br >
15
+ <a :href =" 'https://news.ycombinator.com/threads?id=' + user.id" >comments</a >
16
+ </p >
17
+ </template >
16
18
</div >
17
19
</template >
18
20
You can’t perform that action at this time.
0 commit comments