Skip to content

Commit

Permalink
fix(build): ensure 404 route for /404 page
Browse files Browse the repository at this point in the history
  • Loading branch information
hjvedvik committed Feb 19, 2019
1 parent 8d920fc commit 70698e0
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion gridsome/app/entry.server.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,14 @@ runMain()

export default context => new Promise((resolve, reject) => {
const { app, router } = createApp()
let { url } = context

if (url === '/404') {
url = { name: '404' }
}

context.meta = app.$meta()
router.push(context.url)
router.push(url)

router.onReady(() => {
resolve(app)
Expand Down

0 comments on commit 70698e0

Please sign in to comment.