Sha256: 77ee00b8140209eba55f1b62b0b7658ec39c835e9f6270b72c188350a6bc3437
Contents?: true
Size: 682 Bytes
Versions: 28
Compression:
Stored size: 682 Bytes
Contents
/* MIT License http://www.opensource.org/licenses/mit-license.php Author Tobias Koppers @sokra */ "use strict"; const NullDependency = require("./NullDependency"); class RequireHeaderDependency extends NullDependency { constructor(range) { super(); if (!Array.isArray(range)) throw new Error("range must be valid"); this.range = range; } } RequireHeaderDependency.Template = class RequireHeaderDependencyTemplate { apply(dep, source) { source.replace(dep.range[0], dep.range[1] - 1, "__webpack_require__"); } applyAsTemplateArgument(name, dep, source) { source.replace(dep.range[0], dep.range[1] - 1, "require"); } }; module.exports = RequireHeaderDependency;
Version data entries
28 entries across 27 versions & 9 rubygems