Skip to content

Related Posts plugin #26

@aileen

Description

@aileen

Problem description

It is possible to fetch related posts based on how many tags they have in common. A current implementation of that can be found in the Ghost Docs repository here. This code is very specific to the Ghost Docs requirements and also very messy.

There are probably better solutions to solve this, but this one works and can be a good starting point to create a plugin for the

Proposal

I had a play with this already, trying to add related posts to the GraphQL schema, but wasn't successful. This might be due to my lack of GraphQL knowledge, or simply because it's not possible that way.

The working solution in Ghost Docs inserts the related posts into the PageContext which is another option (not such a nice one, as having it available with a pretty GraphQL query) to implement this.

Maybe (probably) there are even better ways on doing that? This needs further research.

Todos

  • investigate do-ability and different options further
  • write up tech spec and agree on solution with core team
  • implement a general plugin for related Ghost posts, that can be configured
  • publish plugin

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions