karma-ng-html2js-preprocessor
karma-ng-html2js-preprocessor copied to clipboard
html2js: add templatePathReplaces attribute for renaming template paths
This patch implements another config option to the html2js preprocessor, namely it allows the user to transform paths via a list of regexps, instead of passing the cacheIdFromPath callback.
The reason passing that callback is complicated is that it already has some functionality (prependPrefix and stripPrefix), which would have to be reimplemented in the user supplied callback, which is further complicated by the fact that those are stored in the closure hidden from the callback function.
Signed-off-by: Adam Golya [email protected] Signed-off-by: Balazs Scheidler [email protected]