diff --git a/build/build.js b/build/build.js index 2f82af391..563861373 100644 --- a/build/build.js +++ b/build/build.js @@ -32,7 +32,12 @@ async function build(opts) { ]), onwarn: function (message) { if (message.code === 'UNRESOLVED_IMPORT') { - throw new Error(`Could not resolve module ` + message.source + `. Try running 'npm install'`) + throw new Error( + `Could not resolve module ` + + message.source + + `. Try running 'npm install' or using rollup's 'external' option if this is an external dependency. ` + + `Module ${message.source} is imported in ${message.importer}` + ) } } })