diff --git a/lib/read-package-json.js b/lib/read-package-json.js index ba7aa8b..069106e 100644 --- a/lib/read-package-json.js +++ b/lib/read-package-json.js @@ -6,6 +6,8 @@ */ 'use strict' +const readPackage = require('read-package-json-fast') + // ------------------------------------------------------------------------------ // Requirements // ------------------------------------------------------------------------------ @@ -23,7 +25,7 @@ const joinPath = require('path').join */ module.exports = function readPackageJson () { const path = joinPath(process.cwd(), 'package.json') - return import('read-package-json-fast').then(({ default: readPackage }) => readPackage(path)).then(body => ({ + return readPackage(path).then(body => ({ taskList: Object.keys(body.scripts || {}), packageInfo: { path, body } }))