Skip to content

Commit

Permalink
Replacing template path on dist folder to match js file
Browse files Browse the repository at this point in the history
  • Loading branch information
santiagovazquez committed Oct 5, 2015
1 parent 374ce13 commit 866ef19
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
7 changes: 6 additions & 1 deletion Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,10 +160,15 @@ module.exports = function (grunt) {
dist: {
options: {
base: '<%= yeoman.app %>',
module: 'datePicker'
module: 'datePicker',
url: function(templateUrl) {
// on production it should be the same path as the one defined on datePicker.js
return templateUrl.replace('app/', '');
}
},
src: '<%= yeoman.app %>/templates/*.html',
dest: '<%= yeoman.tmp %>/templates.js'

}
},
concurrent: {
Expand Down
4 changes: 2 additions & 2 deletions dist/angular-datepicker.js
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,7 @@ Module.directive('dateTime', ['$compile', '$document', '$filter', 'dateTimeConfi
}]);

angular.module('datePicker').run(['$templateCache', function($templateCache) {
$templateCache.put('app/templates/datepicker.html',
$templateCache.put('templates/datepicker.html',
"<div ng-switch=\"view\">\n" +
" <div ng-switch-when=\"date\">\n" +
" <table>\n" +
Expand Down Expand Up @@ -758,7 +758,7 @@ $templateCache.put('app/templates/datepicker.html',
);


$templateCache.put('app/templates/daterange.html',
$templateCache.put('templates/daterange.html',
"<div>\n" +
" <table>\n" +
" <tr>\n" +
Expand Down
Loading

0 comments on commit 866ef19

Please sign in to comment.