customLogger
option ignored when logging "failed to load config from..." errors
#15824
Labels
customLogger
option ignored when logging "failed to load config from..." errors
#15824
Describe the bug
When invoking the
vite.build()
API programatically, thecustomLogger
option is ignored when reporting an config file load error.Note
The source of this problem appears to be this code in
loadConfigFromFile()
. It's creating a newcreateLogger()
instance, when it should be using thecustomLogger
that gets passed tovite.build()
Reproduction
see steps to reproduce, below
Steps to reproduce
Copy the following code to
vite_config_error_test.mjs
:Then
node vite_config_error_test.mjs
and you should see something like this:System Info
The text was updated successfully, but these errors were encountered: