Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: #1210 - Add error handling for missing dependencies #1232

7 changes: 6 additions & 1 deletion build/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,12 @@ async function build(opts) {
__VERSION__: version,
'process.env.SSR': false
})
])
]),
onwarn: function (message) {
if (message.code === 'UNRESOLVED_IMPORT') {
throw new Error(`Could not resolve module ` + message.source)
mohammedsahl marked this conversation as resolved.
Show resolved Hide resolved
}
}
})
.then(function (bundle) {
var dest = 'lib/' + (opts.output || opts.input)
Expand Down