if I host an angular app at some custom location e.g. http://localhost/collosys
then i have to change all the ng-include to have "/collosys/" for all the addresses, given that i am using absolute address for referring to any html file.
this is how i am doing that currently
<script>
var baseUrl = document.location.pathname;
document.write('<base href="' + document.location.pathname + '" />');
</script>
and then in rewrite ng-include tag
FROM: <div data-ng-include="'/Generic/csgrid/grid-buttons.html'"></div>
TO: <div data-ng-include=" baseUrl + 'Generic/csgrid/grid-buttons.html'"></div>
Can i modify the ng-include tag itself, so that it can prefix all the addresses with the hosting address
EDIT
I read somewhere that angularjs directives are extensible, any example on how to extend angularjs ngInclude directives?? any examples??