Skip to content

cmd/flatend, flathttp: handler for 404 #6

@johnhorsema

Description

@johnhorsema

Suggest to add 404 handler to be configuable under config.toml as follows

[[http.routes]]
code = "404"
service = "notFound"

In Node SDK:

const notFound = async ctx => {
    const fs = require("fs");
    fs.createFileStream("404.html").pipe(ctx);
}

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