Skip to content

Commit dded73a

Browse files
authored
fix: windows vue.config.mjs support (#7023)
1 parent a3ccc3d commit dded73a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/@vue/cli-service/lib/util/loadFileConfig.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
const fs = require('fs')
22
const path = require('path')
3-
3+
const { pathToFileURL } = require('url')
44
const isFileEsm = require('is-file-esm')
55
const { loadModule } = require('@vue/cli-shared-utils')
66

@@ -25,7 +25,7 @@ module.exports = function loadFileConfig (context) {
2525
const { esm } = isFileEsm.sync(fileConfigPath)
2626

2727
if (esm) {
28-
fileConfig = import(fileConfigPath)
28+
fileConfig = import(pathToFileURL(fileConfigPath))
2929
} else {
3030
fileConfig = loadModule(fileConfigPath, context)
3131
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy