Skip to content

Commit

Permalink
[WIP] feat: support es6 module default export (#336)
Browse files Browse the repository at this point in the history
  • Loading branch information
tungv authored and timneutkens committed Jan 19, 2018
1 parent 62f3e45 commit dd2a4bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/handler.js
Expand Up @@ -9,7 +9,7 @@ module.exports = async file => {
mod = await require(file) // Await to support exporting Promises

if (mod && typeof mod === 'object') {
mod = mod.default
mod = await mod.default // Await to support es6 module's default export
}
} catch (err) {
logError(`Error when importing ${file}: ${err.stack}`, 'invalid-entry')
Expand Down

0 comments on commit dd2a4bb

Please sign in to comment.