CommonJsRequireContextDependency.js 647 B

1234567891011121314151617181920212223
  1. /*
  2. MIT License http://www.opensource.org/licenses/mit-license.php
  3. Author Tobias Koppers @sokra
  4. */
  5. "use strict";
  6. const ContextDependency = require("./ContextDependency");
  7. const ContextDependencyTemplateAsRequireCall = require("./ContextDependencyTemplateAsRequireCall");
  8. class CommonJsRequireContextDependency extends ContextDependency {
  9. constructor(options, range, valueRange) {
  10. super(options);
  11. this.range = range;
  12. this.valueRange = valueRange;
  13. }
  14. get type() {
  15. return "cjs require context";
  16. }
  17. }
  18. CommonJsRequireContextDependency.Template = ContextDependencyTemplateAsRequireCall;
  19. module.exports = CommonJsRequireContextDependency;