Skip to content

Metadata & Export refactor #36

Description

@Descent098

Purpose

Refactor the code base to use metadata in generation and simplify process for generating content.

Notes

  • Publicly the only API's that are accessible are
    • ezcv.core.generate_site() & ezcv.core.get_site_config
    • ezcv.filters All functions in here, but importantly will need to support injecting custom filters (and document it)
    • ezcv.content

Major changes

  • When collecting the information about files and their locations, make it easier to access that data one time instead of in 12 different formats. For example, with templates the environment should be passed around since it knows where all the templates' files are, instead of passing the theme name and implicitly finding it every time
  • Should locate top-level files earlier, and make sure to include blog-type sections in those top-level files
  • rewrite image management (filter and export)
  • Move site state into an object that holds all file locations
  • Tag rendering so that multiple blog-type sections can be used
  • Have pages export to folders by section, and make the names url safe (i.e. "My & Post" in the blog section should be at /blog/my-post.html)

Goals

  • Specify section templates that are available using metadata so export can be simplified (specific function to find pages based on metadata)
  • When rendering the pages check if content is available and skip if it's not for a given section (make sure <section_name>_html is set to "" so templates can know if the html is available.
  • Unify blog rendering to be less guess-n-check and also do the rendering of all pages all in one place
  • Write specific way of handling images for galleries
  • Handle standard image exporting

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions