@after-work.js/utils
Advanced tools
Comparing version 6.0.0-dev.20190217.0 to 6.0.0-dev.20190226.0
{ | ||
"name": "@after-work.js/utils", | ||
"version": "6.0.0-dev.20190217.0", | ||
"version": "6.0.0-dev.20190226.0", | ||
"publishConfig": { | ||
@@ -32,3 +32,3 @@ "access": "public" | ||
}, | ||
"gitHead": "fa6c5a05c5b10a9ae5d81b31f3f797170831bd7b" | ||
"gitHead": "3a1138fc9f112a9acd5fd77b1deea4eb2d251bad" | ||
} |
@@ -156,8 +156,9 @@ /* eslint max-len: 0, import/no-dynamic-require: 0, global-require: 0 */ | ||
} | ||
if (typeof opt.babelPluginIstanbul === 'string') { | ||
opt.babelPluginIstanbul = utils.safeGetModule( | ||
opt.babelPluginIstanbul, | ||
).default; | ||
if (opt.enable && typeof opt.babelPluginIstanbul === 'string') { | ||
const babelPluginIstanbul = utils.safeGetModule(opt.babelPluginIstanbul); | ||
opt.babelPluginIstanbul = babelPluginIstanbul | ||
? babelPluginIstanbul.default | ||
: null; | ||
} | ||
if (typeof opt.typescript === 'string') { | ||
if (opt.enable && typeof opt.typescript === 'string') { | ||
opt.typescript = utils.safeGetModule(opt.typescript); | ||
@@ -263,7 +264,16 @@ } | ||
}, | ||
isTestFile(filePath) { | ||
return utils.isMatchingExtPattern(filePath, DEFAULT_TEST_EXT_PATTERN); | ||
isTestFile(filePath, { testExt = DEFAULT_TEST_EXT_PATTERN }) { | ||
return utils.isMatchingExtPattern(filePath, testExt); | ||
}, | ||
isSrcFile( | ||
filePath, | ||
{ testExt = DEFAULT_TEST_EXT_PATTERN, srcExt = DEFAULT_SRC_EXT_PATTERN }, | ||
) { | ||
return ( | ||
!utils.isTestFile(filePath, testExt) | ||
&& utils.isMatchingExtPattern(filePath, srcExt) | ||
); | ||
}, | ||
}; | ||
module.exports = utils; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
9456
270