Nuxt/examples/custom-routes/nuxt.config.js

29 lines
967 B
JavaScript
Raw Normal View History

module.exports = {
2016-12-11 23:15:13 +00:00
router: {
routes: {
2016-12-12 13:16:47 +00:00
// author: {
// alias: '/nuxt'
// },
// users: {
// _id: {
// regexp: ':id(\\d+)'
// // generate: [1, 2, 3, 4] // Need to be finished on generate
// }
// },
// posts: {
// alias: '/articles'
// }
2016-12-11 23:15:13 +00:00
}
},
// generate: {
// routeParams: {
// '/guide/:slug': _(require('./static/docs/guide/menu.json')).values().flatten().map('to').compact().map((slug) => { return { slug: slug.replace(/^\//, '') } }).value(),
// '/api/:slug': _(require('./static/docs/api/menu.json')).values().flatten().map('to').compact().map((slug) => { return { slug: slug.replace(/^\//, '') } }).value(),
// '/examples/:slug': _(require('./static/docs/examples/menu.json')).values().flatten().map('to').compact().map((slug) => { return { slug: slug.replace(/^\//, '') } }).value()
2016-12-11 15:41:52 +00:00
// }
// },
2016-11-27 12:39:52 +00:00
build: {
vendor: ['axios']
2016-11-10 16:16:37 +00:00
}
}