mirror of https://github.com/webpack/webpack.git
default to the default hash function
This commit is contained in:
parent
205d3a05ee
commit
a6bb3e58ec
|
@ -40,7 +40,7 @@ export interface NormalModuleLoaderContext<OptionsType> {
|
||||||
utils: {
|
utils: {
|
||||||
absolutify: (context: string, request: string) => string;
|
absolutify: (context: string, request: string) => string;
|
||||||
contextify: (context: string, request: string) => string;
|
contextify: (context: string, request: string) => string;
|
||||||
createHash: (algorithm: string) => Hash;
|
createHash: (algorithm?: string) => Hash;
|
||||||
};
|
};
|
||||||
rootContext: string;
|
rootContext: string;
|
||||||
fs: InputFileSystem;
|
fs: InputFileSystem;
|
||||||
|
|
|
@ -539,7 +539,9 @@ class NormalModule extends Module {
|
||||||
? getContextifyInContext()(request)
|
? getContextifyInContext()(request)
|
||||||
: getContextify()(context, request);
|
: getContextify()(context, request);
|
||||||
},
|
},
|
||||||
createHash
|
createHash: type => {
|
||||||
|
return createHash(type || compilation.outputOptions.hashFunction);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
const loaderContext = {
|
const loaderContext = {
|
||||||
version: 2,
|
version: 2,
|
||||||
|
|
|
@ -7512,7 +7512,7 @@ declare interface NormalModuleLoaderContext<OptionsType> {
|
||||||
utils: {
|
utils: {
|
||||||
absolutify: (context: string, request: string) => string;
|
absolutify: (context: string, request: string) => string;
|
||||||
contextify: (context: string, request: string) => string;
|
contextify: (context: string, request: string) => string;
|
||||||
createHash: (algorithm: string) => Hash;
|
createHash: (algorithm?: string) => Hash;
|
||||||
};
|
};
|
||||||
rootContext: string;
|
rootContext: string;
|
||||||
fs: InputFileSystem;
|
fs: InputFileSystem;
|
||||||
|
|
Loading…
Reference in New Issue