Python Mercenaries
in
t
g
p
b
f

Lektor Tutorial - pt. 3

Contents

written by Joseph Nix on 2017-04-26

One Folder — One Page

Each page (url) corresponds to one folder in content/. Child pages are nested. Each page has it's content stored in contents.lr and any attachments in the same folder. For example, in the Quickstart State, we have


content/
  contents.lr
  about/
    contents.lr
  blog/
    contents.lr
    first-post/
      contents.lr
  projects/
    contents.lr

Here, the contents.lr files will be rendered to the pages associated with their folders. content/page/path/contents.lr will be rendered to /page/path/.

Each content file is associated with a model and a template. Defaults are determined by Lektor, but can be specified in the CMS when creating the page if non-default models or templates are desired.


« Previous | Lektor Tutorial - pt. 3 | Next »