Skip to content

webpack pulicPath不支持相对路径 #77

Description

@WinfredWang

如下代码

https://github.com/easy-team/easywebpack/blob/master/utils/utils.js#L58

utils.normalizePublicPath = publicPath => {
  publicPath = `${publicPath.replace(/\/$/, '')}/`;
  if (!utils.isHttpOrHttps(publicPath) && !/^\//.test(publicPath)) {
    publicPath = `/${publicPath}`;
  }
  return publicPath;
};

上述代码中publicPath被强制设置成绝对路径,是否可以支持设置相对路径

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions