Kamil Kisiel
9f48112f18
[docs] Document router.Match ( #313 )
...
* Document router.Match
The return values are getting confusing. Hopefully this helps.
* Simplify some language.
* Remove double the
8 years ago
Matt Silverlock
bc452d92e3
[build] Allow tip failures ( #312 )
...
[build] Allow tip failures
8 years ago
Kamil Kisiel
7625a85c14
.travis.yml: Remove versions < go1.5 from build matrix
8 years ago
Mike Busch
c9183aaddd
use req.URL.EscapedPath() instead of getPath(req) ( #306 )
...
This change drops support of go < 1.5. go1.5 has been officially
unsupported since go1.7 was released 2016/08/15.
8 years ago
Paul B. Beskow
10490f55fa
GetQueryTemplates and GetQueryRegexp extraction ( #304 )
...
Developers can now extract the query templates and regexps
from a router as lists of combined query pairs.
8 years ago
Adam Ouellette
9bd9ff2d1d
Added 1.9 build step ( #303 )
8 years ago
Pontus Leitzler
bdd5a5a1b0
Fix WriteHeader in TestA301ResponseWriter. ( #301 )
...
WriteHeader did only set status field for a local copy that was discared
upon return.
8 years ago
Matthew Riley
3f19343c7d
[docs] Document evaluation order for routes ( #297 )
8 years ago
Stephan Renatus
24fca303ac
[docs] README.md: add missing `.` ( #292 )
8 years ago
Matt Silverlock
bb285ea687
[docs] Fix missing space in docstring ( #289 )
8 years ago
Mayank Patel
a659b61323
Fix #271 : Return 405 instead of 404 when request method doesn't match the route
8 years ago
Chris Hines
ac112f7d75
Prefer scheme on child route when building URLs.
9 years ago
Chris Hines
37b3a6cace
Use scheme from parent router when building URLs.
9 years ago
Cody Oss
8c683ee571
Fix typo
9 years ago
Chris Hines
18fca31550
Add test and fix for escaped query values.
...
Reproduces and fixes #238 .
9 years ago
Chris Hines
c7a138dbc1
Update docs.
9 years ago
Pavel Ivanov
f9aa23a02b
Add tests for support for queries in URL reversing.
9 years ago
Pavel Ivanov
9c9af153a1
Add support for queries in URL reversing.
9 years ago
Nick Hudkins
043ee6597c
Update Walking Routes Section
...
Fixed invalid method chaining.
9 years ago
Nick Hudkins
59ce66852b
Fix invalid example code
...
In the "List Routes" example code, `.HandleFunc` was being called on a `*mux.Route` rather than `*mux.Router`. Updated the example code to work :)
9 years ago
Brian Michel
85b8c203a4
Removing half of conflict marker ( #268 )
...
Looks like there was just part of a conflict marker in the README file, so I figured I'd remove it.
9 years ago
Nick Miyake
456bcfa82d
Update README with example for Router.Walk
9 years ago
Nick Miyake
4d814f7650
Update ancestors parameter for WalkFunc for matcher subrouters
...
Fixes #263
9 years ago
Nick Miyake
a322b2c2ec
Update Walk to match all subrouters
...
Matches all routes instead of just routes with paths.
Fixes #261
9 years ago
Chris Hines
bcd8bc72b0
Support building URLs with non-http schemes. ( #260 )
...
* Move misplaced tests and fix comments.
* Support building URLs with non-http schemes.
- Capture first scheme configured for a route for use when building
URLs.
- Add new Route.URLScheme method similar to URLHost and URLPath.
- Update Route.URLHost and Route.URL to use the captured scheme if
present.
* Remove Route.URLScheme method.
* Remove UTF-8 BOM.
9 years ago
Bulat Gaifullin
751308a60a
Updated README
9 years ago
Bulat Gaifullin
b552615e22
Added method Route.GetMethods
9 years ago
Bulat Gaifullin
1856953e53
Added method Route.GetPathRegexp
9 years ago
Carlos Alexandro Becker
4c1c3952b7
fixed typo ( #250 )
9 years ago
Diego Siqueira
599cba5e7b
Fixing Regexp in the benchmark test ( #234 )
...
Signed-off-by: DiSiqueira <dieg0@live.com>
9 years ago
Shane Smith-Sahnow
ad4ce0eb16
updating logic in route matcher, cleaner and saner ( #235 )
9 years ago
Kamil Kisiel
999ef73f5d
Merge pull request #232 from DavidJFelix/patch-1
...
Add sourcegraph badge
9 years ago
David J. Felix
89d16fe9a0
Add sourcegraph badge
...
Fixes #228
9 years ago
Kamil Kisiel
94e7d24fd2
Add Go 1.8 to .travis.yml
9 years ago
Adam Eijdenberg
392c28fe23
[bugfix] fail fast if regex is incorrectly specified using capturing groups. ( #218 )
9 years ago
Shawn Smith
cafdb65e9e
[docs] Add route listing example to README
...
* Update README.md
* Update README.md
9 years ago
Kamil Kisiel
b12896167c
Merge pull request #199 from wirehead/minor-doc-tweek
...
Clarify how route variables work. (#151 )
9 years ago
Kamil Kisiel
34dda716af
Merge pull request #215 from ShaneSaww/fix_for_subroutes_with_pathPrefix
...
Adding in a check for routes with just /
9 years ago
ShaneSaww
b9ff34f617
Adding some extra tests, to hit all the use cases
9 years ago
ShaneSaww
293ebe1493
Adding in a check for routes with just /
9 years ago
Ken Wronkiewicz
910dd3aa31
Remove unnecessary line from example
...
Review comment: setting the header complicates things.
9 years ago
Ken Wronkiewicz
239e05fe53
Clarify how route variables work. ( #151 )
...
(this confused the heck out of me while trying to use Gorilla)
* Changed `request` to be just `r`, like the other handlers.
* Created complete wrapper function instead of just 2 lines.
9 years ago
Kamil Kisiel
757bef944d
Merge pull request #196 from olt/doc-non-capture-groups
...
document non-capturing groups (closes #143 )
9 years ago
Oliver Tonnhofer
14f5df0128
document non-capturing groups ( closes #143 )
9 years ago
Kush Mansingh
0a192a1931
Add useEncodedPath option to router and routes ( #190 )
...
- Resolves a breaking change in #184
9 years ago
Richard Musiol
0b13a92220
Simplify extractVars, fixes edge cases. ( #185 )
...
Also make sure all regexp groups in tests are non-capturing.
9 years ago
Aaron Taylor
34bf6dc9fa
make the getPath method safer, fixing panics within App Engine ( #189 )
9 years ago
Kush Mansingh
674ef1c280
Add mechanism to route based on the escaped path ( #184 )
...
* Add mechanism to route based on the escaped path, correct request mocking in tests
* Remove unneccessary regex matching, substitute with string slicing
* Add test case and handling for requests with no host/scheme
9 years ago
Kamil Kisiel
cf79e51a62
.travis.yml: add go1.7
9 years ago
Matt Silverlock
7804150971
[docs] Add logo to README. ( #180 )
10 years ago