Skip to content

Support blogging-like functionality #1197

Closed
@fgregg

Description

@fgregg

I love where this project is going!

I wonder if y'all would be open to considering adding support for jekyll's blogging pattern.

Namely, that if your markdown file is in a _posts directory, and if its titled like YEAR-MONTH-DAY-title.MARKUP then bloggy things happen:

For jekyll, this means that,

  1. The built html is put into a directory structure to get a nice url that looks like DOMAIN/YEAR/MONTH/DAY/title.html
  2. the page's date is made available to the layout template, so that the published date can be automatically inserted
  3. the site's posts are made available as an object you could interact with sites.posts i.e. to show the latest blog post on the front page jekyll lets you do something like this in an index.md.
---
layout: default
title: My Cool Blog
---

<h1>{{ site.posts.first.title }}</h1>
<p class="text-muted">{{ site.posts.first.date | date: '%B %d, %Y' }} | <a href="{{ site.posts.first.url }}">Permalink</a></p>

{{ site.posts.first.content }}
  1. jekyll does other things as well, but those would be the core of it.

I know that blogs are not your first target use case, but I think it could be a great place to go!

I'd be happy to contribute to this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions