miickel/gulp-angular-templatecache

Url passed to transformUrl should be normalized

Open

#115 创建于 2016年1月12日

在 GitHub 查看
 (11 评论) (0 反应) (0 负责人)JavaScript (97 fork)batch import
help wanted

仓库指标

Star
 (533 star)
PR 合并指标
 (30 天内没有已合并 PR)

描述

On OS X, the url passed to the transformUrl function is normal, e.g. something like components/app/app.html. However, that same url on Windows becomes components//app//app.html.

It seems to be because somewhere along the line the Windows backslashes are converted to forward slashes, and for some reason an additional slash is added. This means you have to take into account when writing the transformUrl function, that the input you get is not going to be consistent across different OS's.

Is it possible to let the gulp-angular-templatecache normalize the url before passing it to the transformUrl function, so that there are no OS dependent differences?

贡献者指南