diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..231a94b --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2014-2016 Evan You + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/README.md b/README.md index 4440d16..c7343c9 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ +> **NOTE**: this demo is using Vue.js 1.x - the 2.0 version is [here](https://github.com/vuejs/vue-hackernews-2.0). + # Vue.js HackerNews clone [Live demo](http://vuejs.github.io/vue-hackernews/) @@ -17,3 +19,7 @@ npm run dev # build: npm run build ``` + +### License + +[MIT](http://opensource.org/licenses/MIT) diff --git a/package.json b/package.json index 56a1293..6721a23 100644 --- a/package.json +++ b/package.json @@ -2,10 +2,9 @@ "name": "vue-hackernews", "version": "1.0.0", "description": "HN clone with Vue.js using HN API", - "main": "index.js", "scripts": { - "dev": "webpack-dev-server --inline --hot --quiet", - "build": "NODE_ENV=production webpack --progress --hide-modules" + "dev": "webpack-dev-server --inline --hot --no-info", + "build": "cross-env NODE_ENV=production webpack --progress --hide-modules" }, "repository": { "type": "git", @@ -18,21 +17,26 @@ }, "homepage": "https://github.com/yyx990803/vue-hackernews", "devDependencies": { - "babel-core": "^5.8.25", - "babel-loader": "^5.3.2", - "babel-runtime": "^5.8.25", - "css-loader": "^0.19.0", - "style-loader": "^0.12.4", - "stylus-loader": "^1.4.0", + "babel-core": "^6.0.0", + "babel-loader": "^6.0.0", + "babel-plugin-transform-runtime": "^6.0.0", + "babel-preset-es2015": "^6.0.0", + "babel-runtime": "^6.0.0", + "cross-env": "^2.0.1", + "css-loader": "^0.24.0", + "stylus": "^0.54.5", + "stylus-loader": "^2.1.1", + "vue-hot-reload-api": "^1.2.0", "vue-html-loader": "^1.0.0", - "vue-loader": "^4.0.0", + "vue-loader": "^8.0.0", + "vue-style-loader": "^1.0.0", "webpack": "^1.12.2", "webpack-dev-server": "^1.12.0" }, "dependencies": { "es6-promise": "^3.0.2", - "firebase": "^2.3.1", - "vue": "^1.0.0-rc.1", - "vue-router": "^0.7.4" + "firebase": "^3.4.1", + "vue": "^1.0.26", + "vue-router": "^0.7.13" } } diff --git a/src/components/App.vue b/src/components/App.vue index a21e605..39271d5 100644 --- a/src/components/App.vue +++ b/src/components/App.vue @@ -8,7 +8,7 @@

Hacker News

Built with Vue.js | - Source + Source diff --git a/src/components/Comment.vue b/src/components/Comment.vue index 22d6a3c..914e83e 100644 --- a/src/components/Comment.vue +++ b/src/components/Comment.vue @@ -19,7 +19,7 @@ import store from '../store' export default { - name: 'comment', // for recursively using self + name: 'Comment', props: { comment: Object diff --git a/src/components/Item.vue b/src/components/Item.vue index cca690f..215130e 100644 --- a/src/components/Item.vue +++ b/src/components/Item.vue @@ -2,7 +2,7 @@
{{index}}.

- {{item.title}} + {{{item.title}}} ({{item.url | domain}}) @@ -14,7 +14,7 @@ {{item.time | fromNow}} ago - | {{item.descendants}} comments + | {{item.descendants}} {{item.descendants | pluralize 'comment'}}

@@ -23,6 +23,8 @@