-
Notifications
You must be signed in to change notification settings - Fork 146
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
html2js-preprocessor adding relative template url #84
Comments
One way I got around this was to use Nodes path module. I set this before the Karma configuration var path = require('path'); Then set the basepath as basePath: path.resolve(), Might help until relative paths are available. |
I set my base path to the root of the folder, './', and it fixed this issue. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
My project folder is at var/www/apps/angular/myproject
And the templates are in the templates folder under myproject.
So the template url is specified in the directive is "/template/directive.html"
So in the karma config I've written
ngHtml2JsPreprocessor: {
stripPrefix: 'var/www/apps/angular/myproject',
moduleName: "my.templates"
},
And this config works. But I don't want to specify the full path to the project in the config because for some other environment this might change. But "myproject" folder will be always there.
So I tried with stripPrefix: '*/myproject',
But it didn't work.
Please tell me how I can fix it?
The text was updated successfully, but these errors were encountered: