allow to pass a function as templateUrl in routes #1193

dcu opened this Issue Jul 21, 2012 · 6 comments


None yet

4 participants

dcu commented Jul 21, 2012

right now you have to do a ugly hack to achieve something similar (for example: )

it would be nice if angularjs allows you to pass a function that receives $routeParams (and $location if possible)

what do you think?

What about parsing the templateUrl for params (just like the route is currently) and using the params from the route to choose the template dynamically?

(I've done this in my fork, jamie-pate@dc9be17 )

dcu commented Sep 3, 2012

did you send a pull request @jamie-pate ?

No, have to jump through legal loopholes first (since I need the corporate CLA signed), also want to run the code on a real site before sending a pr

dcu commented Nov 12, 2012

#1524 is a possible solution for this issue.


Hi @dcu is this still an issue, or was it resolved by: #1524? If it's resolved would you mind closing this issue. Thanks! 👍

@dcu this should be covered by #1524. Closing for now, please reopen if things are still missing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment