Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add legacyRoutes option (#223)
This adds the `legacyRoutes` option, defaulted to `true`. When `legacyRoutes` is true, the `?` character will automatically be escaped: ```ts server.respondWith('GET', '/hello?world', handler); ``` When it is false (future default), `?` has a special meaning in that it denotes which parameters in a path are optional. Due to this, it will not be escaped automatically: ```ts server.respondWith('GET', '/hello\\?world', handler); // so we can have optional params server.respondWith('GET', '/hello/:param?', handler); ```
- Loading branch information