shift73k/assets_old/node_modules/webpack-cli/lib/utils/package-exists.js

9 lines
178 B
JavaScript

function packageExists(packageName) {
try {
return require.resolve(packageName);
} catch (error) {
return false;
}
}
module.exports = packageExists;