ploeh / Hyprlinkr

A URI building helper library for ASP.NET Web API
MIT License
197 stars 34 forks source link

Extensions with UrlHelper #21

Closed jbogard closed 10 years ago

jbogard commented 10 years ago

In the case I don't want to create a RouteLinker, what do you think about extending the UrlHelper inside an ApiController? Something like this:

https://gist.github.com/jbogard/7918898

Obviously I'd namespace this accordingly so that it's opt-in.

ploeh commented 10 years ago

I hadn't thought about that, but it looks like a great addition.

I anyone feels inclined to turn the above gist into a pull request, please don't forget to add some unit tests too :)