Skip to content

Modern Mode Build failed with multiple-pages setup #1683

Closed
@WarWithinMe

Description

@WarWithinMe

Version

3.0.0-rc.3

Reproduction link

https://codesandbox.io/s/k3ox9l4q05?module=%2Fvue.config.js&view=editor

Steps to reproduce

  1. In vue.config.js, add a page config with directory in its "filename":
pages: {
    "privacy/index": {
      entry: "src/privacy.js",
      template: "privacy.html",
      filename: "privacy/index.html"
    }
}
  1. Run vue-cli-service build --modern

What is expected?

vue-cli will generate the page under "dist/privacy/index.html" (dist is default outputDir)

What is actually happening?

vue-cli throws error and halts: (It seems like the issue exists only in Windows)

(node:15008) UnhandledPromiseRejectionWarning: Error: ENOENT: no such file or directory, open '......\dist\legacy-assets-privacy\index.html.json'

If the filename attribute doesn't contain directory, vue-cli will build successfully.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions