Socket
Socket
Sign inDemoInstall

extract-text-webpack-plugin

Package Overview
Dependencies
Maintainers
1
Versions
56
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

extract-text-webpack-plugin - npm Package Compare versions

Comparing version 0.3.3 to 0.3.4

14

index.js

@@ -27,3 +27,2 @@ /*

this.id = id;
this.modulesByIdentifier = {};
}

@@ -96,2 +95,3 @@ module.exports = ExtractTextPlugin;

compiler.plugin("this-compilation", function(compilation) {
var extractCompilation = new ExtractTextPluginCompilation();
compilation.plugin("normal-module-loader", function(loaderContext, module) {

@@ -163,3 +163,3 @@ loaderContext[__dirname] = function(content, opt) {

if(meta.content)
this.addResultToChunk(module.identifier(), meta.content, extractedChunk);
extractCompilation.addResultToChunk(module.identifier(), meta.content, extractedChunk);
callback();

@@ -169,3 +169,3 @@ }.bind(this));

if(meta.content)
this.addResultToChunk(module.identifier(), meta.content, extractedChunk);
extractCompilation.addResultToChunk(module.identifier(), meta.content, extractedChunk);
callback();

@@ -208,2 +208,6 @@ }

function ExtractTextPluginCompilation() {
this.modulesByIdentifier = {};
}
ExtractTextPlugin.prototype.mergeNonInitialChunks = function(chunk, intoChunk, checkedChunks) {

@@ -230,3 +234,3 @@ if(!intoChunk) {

ExtractTextPlugin.prototype.addModule = function(identifier, source, additionalInformation, sourceMap) {
ExtractTextPluginCompilation.prototype.addModule = function(identifier, source, additionalInformation, sourceMap) {
if(!this.modulesByIdentifier[identifier])

@@ -237,3 +241,3 @@ return this.modulesByIdentifier[identifier] = new ExtractedModule(identifier, source, sourceMap, additionalInformation);

ExtractTextPlugin.prototype.addResultToChunk = function(identifier, result, extractedChunk) {
ExtractTextPluginCompilation.prototype.addResultToChunk = function(identifier, result, extractedChunk) {
if(!Array.isArray(result)) {

@@ -240,0 +244,0 @@ result = [[identifier, result]];

{
"name": "extract-text-webpack-plugin",
"version": "0.3.3",
"version": "0.3.4",
"author": "Tobias Koppers @sokra",

@@ -5,0 +5,0 @@ "description": "Extract text from bundle into a file.",

@@ -44,3 +44,6 @@ # extract text plugin for webpack

* `id` Unique ident for this plugin instance. (For advanded usage only)
* `filename` the filename of the result file. May contain `[name]`.
* `filename` the filename of the result file. May contain `[name]`, `[id]` and `[contenthash]`.
* `[name]` the name of the chunk
* `[id]` the number of the chunk
* `[contenthash]` a hash of the content of the extracted file
* `options`

@@ -47,0 +50,0 @@ * `allChunks` extract all chunks (by default only initial chunks)

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