Skip to content

Introduce presenters #188

@marcoow

Description

@marcoow

Currently we're using the entities and changesets in the web crate directly. That's of course easy but also means we're coupling the app's HTTP interface directly to the db crate which is exactly what we want to avoid. We can easily address that via introducing presenters. We can fix that relatively easily by introducing the concept of presenters such that for input data (e.g. when creating an entity), we have a presenter that wraps (or converts to) a changeset and for output (e.g. JSON responses), we have a presenter that wraps or is generated from an entity.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions