mirror of
https://github.com/vuejs/vue-cli.git
synced 2026-01-26 00:59:02 -06:00
chore(ui): display error if plugin loading fail in debug mode
This commit is contained in:
@@ -138,7 +138,11 @@ function runPluginApi (id, context, fileName = 'ui') {
|
||||
let module
|
||||
try {
|
||||
module = loadModule(`${id}/${fileName}`, cwd.get(), true)
|
||||
} catch (e) {}
|
||||
} catch (e) {
|
||||
if (process.env.VUE_CLI_DEBUG) {
|
||||
console.error(e)
|
||||
}
|
||||
}
|
||||
if (module) {
|
||||
pluginApi.pluginId = id
|
||||
module(pluginApi)
|
||||
|
||||
Reference in New Issue
Block a user