Hi there,
I just created a preprocessor for a project, that turns '<%= inlineTemplate("mytpl.html") %>' into '<div>My Template</div>'.
However, I just noticed a problem.
The preprocessor will only refresh the templates in the javascript whenever the javascript files change, but not whenever the templates change.
Here's a run-through of the bug:
1. Create script.js with contents '<%= inlineTemplate("mytpl.html") %>'
2. Create mytpl.html with contents '<div>My Template</div>'
3. Start karma, mytpl.html is put into script.js, test runs successfully
4. Change and save mytpl.html, test re-runs ... but the inline-template preprocessor has not re-run. The old contents of mytpl.html are still in script.js. And the old contents will stay there until I refresh script.js.
So.. is there any easy way I could, from my plugin, make it so all the templates referenced by inlineTemplate() are also added to the watcher list to 're-run' the preprocessor each js file?
Hope my question makes sense!
Thanks :-)