Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

tapable

Package Overview
Dependencies
Maintainers
1
Versions
48
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tapable - npm Package Compare versions

Comparing version 0.2.4 to 0.2.5

41

lib/Tapable.js

@@ -28,2 +28,23 @@ /*

Tapable.prototype.applyPlugins0 = function applyPlugins0(name) {
var plugins = this._plugins[name];
if(!plugins) return;
for(var i = 0; i < plugins.length; i++)
plugins[i].call(this);
};
Tapable.prototype.applyPlugins1 = function applyPlugins1(name, param) {
var plugins = this._plugins[name];
if(!plugins) return;
for(var i = 0; i < plugins.length; i++)
plugins[i].call(this, param);
};
Tapable.prototype.applyPlugins2 = function applyPlugins2(name, param1, param2) {
var plugins = this._plugins[name];
if(!plugins) return;
for(var i = 0; i < plugins.length; i++)
plugins[i].call(this, param1, param2);
};
Tapable.prototype.applyPluginsWaterfall = function applyPluginsWaterfall(name, init) {

@@ -71,7 +92,7 @@ if(!this._plugins[name]) return init;

Tapable.prototype.applyPluginsAsyncSeries = Tapable.prototype.applyPluginsAsync = function applyPluginsAsync(name) {
Tapable.prototype.applyPluginsAsyncSeries = Tapable.prototype.applyPluginsAsync = function applyPluginsAsyncSeries(name) {
var args = Array.prototype.slice.call(arguments, 1);
var callback = args.pop();
if(!this._plugins[name] || this._plugins[name].length === 0) return callback();
var plugins = this._plugins[name];
if(!plugins || plugins.length === 0) return callback();
var i = 0;

@@ -90,2 +111,18 @@ var _this = this;

Tapable.prototype.applyPluginsAsyncSeries1 = function applyPluginsAsyncSeries1(name, param, callback) {
var plugins = this._plugins[name];
if(!plugins || plugins.length === 0) return callback();
var i = 0;
var _this = this;
var innerCallback = copyProperties(callback, function next(err) {
if(err) return callback(err);
i++;
if(i >= plugins.length) {
return callback();
}
plugins[i].call(_this, param, innerCallback);
});
plugins[0].call(this, param, innerCallback);
};
Tapable.prototype.applyPluginsAsyncSeriesBailResult = function applyPluginsAsyncSeriesBailResult(name) {

@@ -92,0 +129,0 @@ var args = Array.prototype.slice.call(arguments, 1);

2

package.json
{
"name": "tapable",
"version": "0.2.4",
"version": "0.2.5",
"author": "Tobias Koppers @sokra",

@@ -5,0 +5,0 @@ "description": "Just a little module for plugins.",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc