ericclemmons / grunt-angular-templates

Grunt build task to concatenate & pre-load your AngularJS templates
MIT License
710 stars 107 forks source link

Add prefix option for the template IDs #50

Closed vitorbaptista closed 11 years ago

vitorbaptista commented 11 years ago

I'm using $locationProvider.html5Mode(true), so my templates have to be absolute, not relative. I tried using src: '/views/*.html', but it didn't work.

In the end, I couldn't figure out how to do it, so I used grunt-angular-inline-templates. They have a prefix options, which makes it trivial to solve this issue (https://github.com/wmluke/grunt-inline-angular-templates#optionsprefix).

I'm not sure if there's another way to solve my issue but, if not, adding this option sounds easy and good enough. If you agree, I'd be happy to send a pull request. What do you think?

ericclemmons commented 11 years ago

So you tried using a callback and it didn't work?

https://github.com/ericclemmons/grunt-angular-templates/blob/master/Gruntfile.js#L173

ericclemmons commented 11 years ago

@vitorbaptista Check out #53, which should resolve this.

vitorbaptista commented 11 years ago

Thanks! That should work :+1: :D