Implemententing /Newsletter page

Dearl all, I hope you are all doing great!

I am trying to implement the recipe described here https://ghost.org/docs/members/recipes/?_ga=2.163179836.1881283652.1582541655-1616121161.1582541655#newsletter-directory.

The intention is to create a newsletter directory and what I am doing is simply pasting the code bellow in the sequence of the Route file of Lyra Theme:

collections:
  /:
    permalink: /{slug}/
    template: index
    filter: visibility:public
  /newsletter/:
    permalink: /{slug}/
    template: index
    filter: visibility:-public

This is the error message I displayed: “bad indentation of a mapping entry at line 11, column 3: /newsletter/: ^”

What would the root cause for that?

:wave: hi there!

Your routes.yaml file needs to adhere to very strict indentation rules (2 spaces, no use of tab)

Looks like you have some incorrect indentation on line 11 in your file. Maybe an extra space managed to get in there?

You can always try pasting your full routes.yaml into a tool like: http://www.yamllint.com/

1 Like

Hello there! Worked :slight_smile:

1 Like