Permalink
Browse files

add public dir + big icons

1 parent 47294d7 commit 4f92d4ec184aad36c1b451740adacd4905d1e90f @yyx990803 yyx990803 committed Nov 14, 2016
@@ -20,6 +20,11 @@ module.exports = {
publicPath: '/dist/',
filename: '[name].[chunkhash].js'
},
+ resolve: {
+ alias: {
+ 'public': path.resolve(__dirname, '../public')
+ }
+ },
module: {
noParse: /es6-promise\.js$/, // avoid webpack shimming process
rules: [
@@ -7,9 +7,9 @@ const SWPrecachePlugin = require('sw-precache-webpack-plugin')
const config = Object.assign({}, base, {
resolve: {
- alias: {
+ alias: Object.assign({}, base.resolve.alias, {
'create-api': './create-api-client.js'
- }
+ })
},
plugins: (base.plugins || []).concat([
// strip comments in Vue code
@@ -10,9 +10,9 @@ module.exports = Object.assign({}, base, {
libraryTarget: 'commonjs2'
}),
resolve: {
- alias: {
+ alias: Object.assign({}, base.resolve.alias, {
'create-api': './create-api-server.js'
- }
+ })
},
externals: Object.keys(require('../package.json').dependencies),
plugins: [
View
@@ -2,8 +2,24 @@
"name": "Vue Hackernews 2.0",
"short_name": "Vue HN",
"icons": [{
- "src": "/logo.png",
- "sizes": "48x48",
+ "src": "/public/logo-120.png",
+ "sizes": "120x120",
+ "type": "image/png"
+ }, {
+ "src": "/public/logo-144.png",
+ "sizes": "144x144",
+ "type": "image/png"
+ }, {
+ "src": "/public/logo-152.png",
+ "sizes": "152x152",
+ "type": "image/png"
+ }, {
+ "src": "/public/logo-192.png",
+ "sizes": "192x192",
+ "type": "image/png"
+ },{
+ "src": "/public/logo-384.png",
+ "sizes": "384x384",
"type": "image/png"
}],
"start_url": "/",
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View
@@ -54,11 +54,11 @@ const serve = (path, cache) => express.static(resolve(path), {
})
app.use(compression({ threshold: 0 }))
-app.use(favicon('./src/assets/logo.png'))
+app.use(favicon('./public/logo-48.png'))
app.use('/service-worker.js', serve('./dist/service-worker.js'))
app.use('/manifest.json', serve('./manifest.json'))
-app.use('/logo.png', serve('./src/assets/logo.png'))
app.use('/dist', serve('./dist'))
+app.use('/public', serve('./public'))
app.get('*', (req, res) => {
if (!renderer) {
View
@@ -3,7 +3,7 @@
<div class="header">
<div class="inner">
<router-link to="/" exact>
- <img class="logo" src="./assets/logo.png" alt="logo">
+ <img class="logo" src="~public/logo-48.png" alt="logo">
</router-link>
<router-link to="/top">Top</router-link>
<router-link to="/new">New</router-link>
View
Deleted file not rendered

0 comments on commit 4f92d4e

Please sign in to comment.