Daniel15 / RouteJs

JavaScript URL routing for ASP.NET MVC and WebForms
84 stars 19 forks source link

ASP.NET WebAPI support #9

Open Daniel15 opened 11 years ago

devmondo commented 11 years ago

hi, any update on this?

thanks in advanced

Daniel15 commented 11 years ago

I was waiting for someone to ask about it before implementing it, didn't want to implement something that wouldn't be used :)

How do you normally build URLs for ASP.NET WebAPI?

devmondo commented 11 years ago

hahah, thanks for reply, before i started using Angular.js i was building it using Url.Action method, which is pretty cool as you get syntax intellisense with visual studio, but now after i have gone completely client side and using WebApi for Ajax calls, i am only left with manually typing url like "/api/customers".

i was hoping that your library will bring back the goodness of Url.Action Method :) thanks in advanced.

wassertim commented 11 years ago

That would be nice to have :+1:

jhnwsk commented 10 years ago

Me too. Also using angular.js + ASP.NET WebAPI :+1:

fcastells commented 10 years ago

I was looking for this feature too. Actually, I see this package being useful mostly for WebApi, were most calls from client code are directed too nowadays. At the moment what I do is: I have a RouteDescriptor class with name and pattern properties. Then with razor, I put all the patterns as properties of a js object and when I want a route url I use the corresponding property doing a replace for the parameters, something like routes.Products.replace('{productId}', id); But with this package, I see it more like using controller and action names instead.

ermish commented 9 years ago

+1

posledam commented 9 years ago

Yes! Ya ya, da da da... :)

okolobaxa commented 8 years ago

Hello! Will RouteJs support WebAPI routes?