Home

Issue: 2620

Router :: param doesn't want to be optional

[issue link]

Desired Outcome

My goal is to have a topic/:slug? route, that would look like the following in a non-nuxt vue project:

screen shot 2018-01-17 at 6 21 01 pm

e.g to have a slug as an optional parameter for the /topic route.

The Problem

My pages folder looks like this:

screen shot 2018-01-24 at 8 55 31 pm

However, the result is /topic/:slug instead of /topic/:slug?:

screen shot 2018-01-17 at 6 25 51 pm

What am I doing wrong? Is it a bug?

This question is available on Nuxt.js community (#c2279)