Skip to content

构建后public内子目录里的所有index.html文件丢失 #2144

@haveam

Description

@haveam

Version

3.0.0-rc.12

Node and OS info

v8

Steps to reproduce

在public下创建相关文件结构如下:

/public
   /aa
     index.html
     index2.html
  /bb
     index.html
     index2.html
  ...

执行 npm run build 构建

What is expected?

期望相关文件正常保留。

What is actually happening?

在构建后的aa,bb目录下的index.html文件全部丢失。


发现这个问题造成的原因是:https://github.com/vuejs/vue-cli/blob/dev/packages/%40vue/cli-service/lib/config/app.js#L150。
默认不会复制index.html。这个的默认值是一个固定值,期望可以配置或则保留index.html。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions