webworkify-webpack
Advanced tools
Comparing version 1.1.6 to 1.1.7
var __webpack_require__ = arguments[2]; | ||
var sources = __webpack_require__.m; | ||
var ENTRY_MODULE = __webpack_require__.s || "0"; | ||
// In webpack 2 the moduleId property is called `i` instead of `id`. | ||
@@ -35,3 +36,3 @@ var webworkifyWebpackModuleId = arguments[0].id || arguments[0].i; | ||
var moduleWrapperStrings = []; | ||
var potentialFnModuleIds = []; | ||
var potentialFnModuleIds = [ENTRY_MODULE]; | ||
@@ -92,3 +93,3 @@ var sourcesKeys = Object.keys(sources); // when using the CommonChunks plugin, webpacl sometimes storing sources in object instead of array | ||
if (!(exp && (exp === fn || exp.default === fn))) { | ||
sources[moduleId] = wrapperFuncString.substring(0, wrapperFuncString.length - 1) + '\n' + fnString.match(/function\s?(.+?)\s?\(.*/)[1] + '();\n}'; | ||
moduleWrapperStrings[moduleId] = wrapperFuncString.substring(0, wrapperFuncString.length - 1) + '\n' + fnString.match(/function\s?(.+?)\s?\(.*/)[1] + '();\n}'; | ||
} | ||
@@ -95,0 +96,0 @@ |
{ | ||
"name": "webworkify-webpack", | ||
"version": "1.1.6", | ||
"version": "1.1.7", | ||
"description": "launch a web worker that can require() in the browser with webpack", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
10606
151