Skip to content

Option to treat plus signs (+) as spaces #66

Description

@yndx-madfriend

It is common to use literal plus sign in query string as a synonym of space, and many websites support this:
https://google.com?q=foo+bar.

The w3c spec says:

Within the query string, the plus sign is reserved as shorthand notation for a space. Therefore, real plus signs must be encoded. This method was used to make query URIs easier to pass in systems which did not allow spaces.

However, there is a debate whether url encoding / decoding should treat plus signs this way, see https://stackoverflow.com/questions/5450190/how-to-encode-the-plus-symbol-in-a-url.

Can path-parser (and router5) have an option to enable such encoding/decoding of plus signs?

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