webpack: Add Configuration.Resolve.cacheWithContext (#25209)

https://webpack.js.org/configuration/resolve/#resolve-cachewithcontext
This commit is contained in:
Christophe Hurpeau
2018-04-25 01:00:59 +02:00
committed by Wesley Wigham
parent d931a0ceb6
commit 2f1a4cda5c
2 changed files with 18 additions and 0 deletions

View File

@@ -11,6 +11,7 @@
// Spencer Elliott <https://github.com/elliottsj>
// Jason Cheatham <https://github.com/jason0x43>
// Dennis George <https://github.com/dennispg>
// Christophe Hurpeau <https://github.com/christophehurpeau>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.3
@@ -320,6 +321,14 @@ declare namespace webpack {
* Defaults to `true`
*/
symlinks?: boolean;
/**
* If unsafe cache is enabled, includes request.context in the cache key.
* This option is taken into account by the enhanced-resolve module.
* Since webpack 3.1.0 context in resolve caching is ignored when resolve or resolveLoader plugins are provided.
* This addresses a performance regression.
*/
cacheWithContext?: boolean;
}
interface ResolveLoader extends Resolve {

View File

@@ -10,6 +10,7 @@
// Alan Agius <https://github.com/alan-agius4>
// Spencer Elliott <https://github.com/elliottsj>
// Jason Cheatham <https://github.com/jason0x43>
// Christophe Hurpeau <https://github.com/christophehurpeau>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.2
@@ -318,6 +319,14 @@ declare namespace webpack {
* Defaults to `true`
*/
symlinks?: boolean;
/**
* If unsafe cache is enabled, includes request.context in the cache key.
* This option is taken into account by the enhanced-resolve module.
* Since webpack 3.1.0 context in resolve caching is ignored when resolve or resolveLoader plugins are provided.
* This addresses a performance regression.
*/
cacheWithContext?: boolean;
}
interface ResolveLoader extends Resolve {