1 |
|
2 |
|
3 |
|
4 |
|
5 | "use strict";
|
6 |
|
7 | const RuntimeGlobals = require("../RuntimeGlobals");
|
8 | const RuntimeModule = require("../RuntimeModule");
|
9 |
|
10 |
|
11 |
|
12 | class GetFullHashRuntimeModule extends RuntimeModule {
|
13 | constructor() {
|
14 | super("getFullHash");
|
15 | this.fullHash = true;
|
16 | }
|
17 |
|
18 | |
19 |
|
20 |
|
21 | generate() {
|
22 | const { runtimeTemplate } = this.compilation;
|
23 | return `${RuntimeGlobals.getFullHash} = ${runtimeTemplate.returningFunction(
|
24 | JSON.stringify(this.compilation.hash || "XXXX")
|
25 | )}`;
|
26 | }
|
27 | }
|
28 |
|
29 | module.exports = GetFullHashRuntimeModule;
|