webpack-virtual-modules
Advanced tools
Comparing version 0.3.0 to 0.3.1
@@ -191,2 +191,4 @@ var VirtualStats = require('./virtual-stats'); | ||
setData(fileStorage, file, createWebpackData(contents)); | ||
self._compiler.fileTimestamps instanceof Map && | ||
self._compiler.fileTimestamps.set(file, +stats.mtime); | ||
var segments = file.split(/[\\/]/); | ||
@@ -247,2 +249,9 @@ var count = segments.length - 1; | ||
self._watcher = watcher.compiler || watcher; | ||
const virtualFiles = self._compiler.inputFileSystem._virtualFiles; | ||
if (virtualFiles) { | ||
Object.keys(virtualFiles).forEach(function(file) { | ||
self._compiler.fileTimestamps instanceof Map && | ||
self._compiler.fileTimestamps.set(file, +virtualFiles[file].stats.mtime); | ||
}); | ||
} | ||
callback(); | ||
@@ -249,0 +258,0 @@ } |
{ | ||
"name": "webpack-virtual-modules", | ||
"version": "0.3.0", | ||
"version": "0.3.1", | ||
"description": "Webpack Virtual Modules", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -24,4 +24,3 @@ # Webpack Virtual Modules | ||
You can use Webpack Virtual Modules with webpack 3 and 4. The examples below show the usage with webpack 4 and its | ||
latest API for hooks. If you want to use our plugin with webpack 3, check out a dedicated doc: | ||
You can use Webpack Virtual Modules with webpack 5, 4 and 3. The examples below show the usage with webpack 5 or 4. If you want to use our plugin with webpack 3, check out a dedicated doc: | ||
@@ -100,4 +99,5 @@ * [Webpack Virtual Modules with Webpack 3] | ||
- [Swagger and JSDoc Example with Webpack 5] | ||
- [Swagger and JSDoc Example with Webpack 4] | ||
- [Swagger and JSDoc Example with Webpack 3] | ||
- [Swagger and JSDoc Example with Webpack 4] | ||
@@ -120,2 +120,3 @@ ## API Reference | ||
[swagger and jsdoc example with webpack 4]: https://github.com/sysgears/webpack-virtual-modules/tree/master/examples/swagger-webpack4 | ||
[swagger and jsdoc example with webpack 5]: https://github.com/sysgears/webpack-virtual-modules/tree/master/examples/swagger-webpack5 | ||
[api reference]: https://github.com/sysgears/webpack-virtual-modules/tree/master/docs/API%20Reference.md | ||
@@ -122,0 +123,0 @@ [virtual-module-webpack-plugin]: https://github.com/rmarscher/virtual-module-webpack-plugin |
17052
313
123