UNPKG

webpack

Version:

Packs ECMAScript/CommonJs/AMD modules for the browser. Allows you to split your codebase into multiple bundles, which can be loaded on demand. Supports loaders to preprocess files, i.e. json, jsx, es7, css, less, ... and your custom stuff.

40 lines (32 loc) • 1.16 kB
/* MIT License http://www.opensource.org/licenses/mit-license.php Author Tobias Koppers @sokra */ "use strict"; const makeSerializable = require("../../util/makeSerializable"); const { ImportPhase } = require("../core/ImportPhase"); const NullDependency = require("../core/NullDependency"); const ESMImportDependency = require("./ESMImportDependency"); class ESMAcceptImportDependency extends ESMImportDependency { /** * Creates an instance of ESMAcceptImportDependency. * @param {string} request the request string */ constructor(request) { super(request, Infinity, ImportPhase.Evaluation); /** @type {boolean} */ this.weak = true; } get type() { return "harmony accept"; } } makeSerializable(ESMAcceptImportDependency, [ "webpack/lib/dependencies/esm/ESMAcceptImportDependency", // TODO in the next major release: remove, it restores the packs written // under the name the file had before the ESM rename "webpack/lib/dependencies/HarmonyAcceptImportDependency" ]); ESMAcceptImportDependency.Template = /** @type {typeof ESMImportDependency.Template} */ (NullDependency.Template); module.exports = ESMAcceptImportDependency;