nextra icon indicating copy to clipboard operation
nextra copied to clipboard

creating multiple blog lists

Open joelgrimberg opened this issue 3 years ago • 3 comments

Is it possible to create 2 blogs in 1 app? suppose I want |home| blog | small-notes so they will not mingle in 1 big list of articles?

joelgrimberg avatar May 24 '22 14:05 joelgrimberg

I was also thinking of making a TIL section on my website. It could be done via navs field in theme.config.js but its behavior is a bit different than other links.

export default {
    // ...
    navs: [
        {
            url: "/til",
            name: "TIL",
        },
    ],
};

numToStr avatar Aug 02 '22 10:08 numToStr

You can take a look how https://github.com/vercel/swr-site/tree/main/pages handles "/blog". It has a blog.en-US.mdx page as well as a blog directory.

shuding avatar Aug 02 '22 11:08 shuding

Thanks @shuding for the pointer. I could get it to working but apparently anything under pages/til is also shown by type: posts page, which I don't want. I guess, I have to lose the type: posts If I go with something custom.

My use case is to render everything inside pages/blog/* under /blog path and pages/til/* under /til, and styling should be similar to what we get with type: posts :)

numToStr avatar Aug 02 '22 12:08 numToStr