Sha256: 83e5894b19ecfd2a896757f4475e50e741cf331889d04772b85fed6bdb20cef8

Contents?: true

Size: 658 Bytes

Versions: 11

Compression:

Stored size: 658 Bytes

Contents

/*
	MIT License http://www.opensource.org/licenses/mit-license.php
	Author Tobias Koppers @sokra
*/

"use strict";

const ConcatSource = require("webpack-sources").ConcatSource;

class NodeChunkTemplatePlugin {

	apply(chunkTemplate) {
		chunkTemplate.plugin("render", function(modules, chunk) {
			const source = new ConcatSource();
			source.add(`exports.ids = ${JSON.stringify(chunk.ids)};\nexports.modules = `);
			source.add(modules);
			source.add(";");
			return source;
		});
		chunkTemplate.plugin("hash", function(hash) {
			hash.update("node");
			hash.update("3");
		});
	}
}

module.exports = NodeChunkTemplatePlugin;

Version data entries

11 entries across 7 versions & 4 rubygems

Version Path
ilog-0.4.1 node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
ilog-0.4.0 node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
ilog-0.3.3 node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
optimacms-0.4.3 spec/dummy/node_modules/@rails/webpacker/node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
optimacms-0.4.3 spec/dummy/node_modules/@rails/webpacker/node_modules/webpack/node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
optimacms-0.4.3 spec/dummy/node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
optimacms-0.4.2 spec/dummy/node_modules/@rails/webpacker/node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
optimacms-0.4.2 spec/dummy/node_modules/@rails/webpacker/node_modules/webpack/node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
optimacms-0.4.2 spec/dummy/node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
cortex-0.1.3 spec/dummy/node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js
lanes-0.8.0 node_modules/webpack/lib/node/NodeChunkTemplatePlugin.js