babel-plugin-normalize-requires
Advanced tools
Comparing version 1.7.0-alpha.e4d06b30 to 1.7.0
@@ -7,6 +7,2 @@ 'use strict'; | ||
var _babelIpc = require('liferay-npm-build-tools-common/lib/babel-ipc'); | ||
var babelIpc = _interopRequireWildcard(_babelIpc); | ||
var _pluginLogger = require('liferay-npm-build-tools-common/lib/plugin-logger'); | ||
@@ -27,5 +23,3 @@ | ||
beforeEach(function () { | ||
babelIpc.set(__filename, { | ||
log: logger = new _pluginLogger2.default() | ||
}); | ||
_pluginLogger2.default.set(__filename, logger = new _pluginLogger2.default()); | ||
}); | ||
@@ -32,0 +26,0 @@ |
@@ -51,10 +51,3 @@ 'use strict'; | ||
if (state.normalizeCount) { | ||
var _babelIpc$get = babelIpc.get(state, function () { | ||
return { | ||
log: new _pluginLogger2.default() | ||
}; | ||
}), | ||
log = _babelIpc$get.log; | ||
log.info('normalize-requires', 'Normalized', state.normalizeCount, 'requires'); | ||
_pluginLogger2.default.get(state).info('normalize-requires', 'Normalized', state.normalizeCount, 'requires'); | ||
} | ||
@@ -67,6 +60,2 @@ } | ||
var _babelIpc = require('liferay-npm-build-tools-common/lib/babel-ipc'); | ||
var babelIpc = _interopRequireWildcard(_babelIpc); | ||
var _pluginLogger = require('liferay-npm-build-tools-common/lib/plugin-logger'); | ||
@@ -78,4 +67,2 @@ | ||
function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } } | ||
/** | ||
@@ -82,0 +69,0 @@ * Check whether a module name refers to a package entry point. |
{ | ||
"name": "babel-plugin-normalize-requires", | ||
"version": "1.7.0-alpha.e4d06b30", | ||
"version": "1.7.0", | ||
"description": "A Babel plugin that rewrites require() calls to normalize them (removing extensions and trailing slashes, for example).", | ||
@@ -15,4 +15,4 @@ "main": "lib/index.js", | ||
"dependencies": { | ||
"liferay-npm-build-tools-common": "1.7.0-alpha.e4d06b30" | ||
"liferay-npm-build-tools-common": "1.7.0" | ||
} | ||
} |
import * as babel from 'babel-core'; | ||
import * as babelIpc from 'liferay-npm-build-tools-common/lib/babel-ipc'; | ||
import PluginLogger from 'liferay-npm-build-tools-common/lib/plugin-logger'; | ||
@@ -9,5 +8,3 @@ import plugin from '../index'; | ||
beforeEach(() => { | ||
babelIpc.set(__filename, { | ||
log: (logger = new PluginLogger()), | ||
}); | ||
PluginLogger.set(__filename, (logger = new PluginLogger())); | ||
}); | ||
@@ -14,0 +11,0 @@ |
@@ -1,2 +0,1 @@ | ||
import * as babelIpc from 'liferay-npm-build-tools-common/lib/babel-ipc'; | ||
import PluginLogger from 'liferay-npm-build-tools-common/lib/plugin-logger'; | ||
@@ -57,7 +56,3 @@ | ||
if (state.normalizeCount) { | ||
const {log} = babelIpc.get(state, () => ({ | ||
log: new PluginLogger(), | ||
})); | ||
log.info( | ||
PluginLogger.get(state).info( | ||
'normalize-requires', | ||
@@ -64,0 +59,0 @@ 'Normalized', |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
1
24186
346
+ Addedliferay-npm-build-tools-common@1.7.0(transitive)
- Removedliferay-npm-build-tools-common@1.7.0-alpha.e4d06b30(transitive)