add a separate class for HotUpdateChunk
This commit is contained in:
parent
a4e8c07f09
commit
3677e25c30
|
@ -0,0 +1,16 @@
|
|||
/*
|
||||
MIT License http://www.opensource.org/licenses/mit-license.php
|
||||
Author Tobias Koppers @sokra
|
||||
*/
|
||||
"use strict";
|
||||
|
||||
const Chunk = require("./Chunk");
|
||||
|
||||
class HotUpdateChunk extends Chunk {
|
||||
constructor() {
|
||||
super();
|
||||
this.removedModules = undefined;
|
||||
}
|
||||
}
|
||||
|
||||
module.exports = HotUpdateChunk;
|
|
@ -5,7 +5,7 @@
|
|||
"use strict";
|
||||
|
||||
const Template = require("./Template");
|
||||
const Chunk = require("./Chunk");
|
||||
const HotUpdateChunk = require("./HotUpdateChunk");
|
||||
const { Tapable, SyncWaterfallHook, SyncHook } = require("tapable");
|
||||
|
||||
module.exports = class HotUpdateChunkTemplate extends Tapable {
|
||||
|
@ -41,7 +41,7 @@ module.exports = class HotUpdateChunkTemplate extends Tapable {
|
|||
moduleTemplate,
|
||||
dependencyTemplates
|
||||
) {
|
||||
const hotUpdateChunk = new Chunk();
|
||||
const hotUpdateChunk = new HotUpdateChunk();
|
||||
hotUpdateChunk.id = id;
|
||||
hotUpdateChunk.setModules(modules);
|
||||
hotUpdateChunk.removedModules = removedModules;
|
||||
|
|
Loading…
Reference in New Issue