2013-07-11 05:20:07 +08:00
|
|
|
/*
|
|
|
|
|
MIT License http://www.opensource.org/licenses/mit-license.php
|
|
|
|
|
Author Tobias Koppers @sokra
|
|
|
|
|
*/
|
|
|
|
|
function WebEnvironmentPlugin(inputFileSystem, outputFileSystem) {
|
|
|
|
|
this.inputFileSystem = inputFileSystem;
|
|
|
|
|
this.outputFileSystem = outputFileSystem;
|
|
|
|
|
}
|
|
|
|
|
module.exports = WebEnvironmentPlugin;
|
|
|
|
|
WebEnvironmentPlugin.prototype.apply = function(compiler) {
|
|
|
|
|
var inputFileSystem = compiler.inputFileSystem = this.inputFileSystem;
|
2015-04-24 05:55:50 +08:00
|
|
|
compiler.resolvers.normal.fileSystem = inputFileSystem;
|
|
|
|
|
compiler.resolvers.context.fileSystem = inputFileSystem;
|
|
|
|
|
compiler.resolvers.loader.fileSystem = inputFileSystem;
|
2013-07-11 05:20:07 +08:00
|
|
|
compiler.outputFileSystem = this.outputFileSystem;
|
2015-07-08 20:39:02 +08:00
|
|
|
};
|