javoire / browserify-ng-html2js

Browserify transform to compile html templates into angular template modules
MIT License
27 stars 17 forks source link

How to specify folder for template module? #35

Closed artemgrygor closed 8 years ago

artemgrygor commented 8 years ago

Hi, looks like a very simple issue but have no idea how to do it correctly. In the app there are router.js

$routeProvider .when('/tutor/dashboard', { templateUrl: '/views/tutor/components/dashboard.html', controller: 'DashboardCtrl', controllerAs: 'vm' })

which is located in one folder. And of course, the entry point main.js where I'm trying to require the template require('./views/tutor/components/dashboard/dashboard.html'); or like this (which is an actual path) require('../../../views/tutor/components/dashboard/dashboard.html');

Both of this give the error during browserify process that cannot find a module on the folder where the router.js is located. Any suggestions?

javoire commented 8 years ago

Hey! Sorry for late answer. Did you figure it out?

artemgrygor commented 8 years ago

@javoire no problem. Yes, it works. The issue could be closed now