Skip to content

simplify plugin route creation #1560

Description

@deer

#1545 recently simplified the way that plugin authors specify middleware. We should do a similar simplification for routes: don't require slashes at the beginning, as this is confusing. The plugin loader does this:

`./routes${route.path}.ts`

but it should instead check to see if route.path has a leading slash, and add one if not present. We'll need tests for this new functionality, and to make sure the old style doesn't break.

@bjesuiter, I think this is the last of the work resulting from our discussion.

from: #1545 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions