update config example auth-routes

This commit is contained in:
Alexandre Chopin 2016-12-08 16:39:27 +01:00
parent 4895433d33
commit 4d7102c3e1
2 changed files with 14 additions and 1 deletions

View File

@ -0,0 +1,11 @@
module.exports = {
head: {
title: 'Auth Routes',
meta: [
{ charset: 'utf-8' },
{ name: 'viewport', content: 'width=device-width, initial-scale=1' },
{ hid: 'description', content: 'Auth Routes example' }
]
},
loading: { color: '#3B8070' }
}

View File

@ -31,7 +31,9 @@ app.post('/api/logout', function (req, res) {
// We instantiate Nuxt.js with the options
const isProd = process.env.NODE_ENV === 'production'
const nuxt = new Nuxt({ dev: !isProd })
let config = require('./nuxt.config.js')
config.dev = !isProd
const nuxt = new Nuxt(config)
// No build in production
const promise = (isProd ? Promise.resolve() : nuxt.build())
promise.then(() => {