Skip to content

windows 下运行 webpack 5,使用 art-template-loader 路径解析出现错误 #633

@kamilic

Description

@kamilic

如果 .art 文件放在 node_modules 上会导致路径解析出现问题。
测试过 *nix 下系统都不会有问题,只有 windows 出现这个问题。

我在 art-template 的包上改过了,只需要把 precompile.js 的 tplImportsPath 使用 slash 包统一一下路径就能正确运行。
https://github.com/aui/art-template/blob/master/src/precompile.js#L249

重现问题仓库请看
https://github.com/kamilic/atl-production

如果有需要提交 PR,我可以进行修改。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions