a zip code crypto-currency system good for red ONLY

NodeChunkTemplatePlugin.js 631B

12345678910111213141516171819202122232425262728
  1. /*
  2. MIT License http://www.opensource.org/licenses/mit-license.php
  3. Author Tobias Koppers @sokra
  4. */
  5. "use strict";
  6. const ConcatSource = require("webpack-sources").ConcatSource;
  7. class NodeChunkTemplatePlugin {
  8. apply(chunkTemplate) {
  9. chunkTemplate.plugin("render", function(modules, chunk) {
  10. const source = new ConcatSource();
  11. source.add(`exports.ids = ${JSON.stringify(chunk.ids)};\nexports.modules = `);
  12. source.add(modules);
  13. source.add(";");
  14. return source;
  15. });
  16. chunkTemplate.plugin("hash", function(hash) {
  17. hash.update("node");
  18. hash.update("3");
  19. });
  20. }
  21. }
  22. module.exports = NodeChunkTemplatePlugin;