main
Last change
on this file since 79a0317 was 79a0317, checked in by stefan toskovski <stefantoska84@…>, 4 days ago |
F4 Finalna Verzija
|
-
Property mode
set to
100644
|
File size:
1.1 KB
|
Line | |
---|
1 | /*
|
---|
2 | MIT License http://www.opensource.org/licenses/mit-license.php
|
---|
3 | Author Tobias Koppers @sokra, Zackary Jackson @ScriptedAlchemy, Marais Rossouw @maraisr
|
---|
4 | */
|
---|
5 |
|
---|
6 | "use strict";
|
---|
7 |
|
---|
8 | const Dependency = require("../Dependency");
|
---|
9 | const makeSerializable = require("../util/makeSerializable");
|
---|
10 |
|
---|
11 | /** @typedef {import("./ContainerEntryModule").ExposeOptions} ExposeOptions */
|
---|
12 | /** @typedef {import("./ContainerEntryModule").ExposesList} ExposesList */
|
---|
13 |
|
---|
14 | class ContainerEntryDependency extends Dependency {
|
---|
15 | /**
|
---|
16 | * @param {string} name entry name
|
---|
17 | * @param {ExposesList} exposes list of exposed modules
|
---|
18 | * @param {string} shareScope name of the share scope
|
---|
19 | */
|
---|
20 | constructor(name, exposes, shareScope) {
|
---|
21 | super();
|
---|
22 | this.name = name;
|
---|
23 | this.exposes = exposes;
|
---|
24 | this.shareScope = shareScope;
|
---|
25 | }
|
---|
26 |
|
---|
27 | /**
|
---|
28 | * @returns {string | null} an identifier to merge equal requests
|
---|
29 | */
|
---|
30 | getResourceIdentifier() {
|
---|
31 | return `container-entry-${this.name}`;
|
---|
32 | }
|
---|
33 |
|
---|
34 | get type() {
|
---|
35 | return "container entry";
|
---|
36 | }
|
---|
37 |
|
---|
38 | get category() {
|
---|
39 | return "esm";
|
---|
40 | }
|
---|
41 | }
|
---|
42 |
|
---|
43 | makeSerializable(
|
---|
44 | ContainerEntryDependency,
|
---|
45 | "webpack/lib/container/ContainerEntryDependency"
|
---|
46 | );
|
---|
47 |
|
---|
48 | module.exports = ContainerEntryDependency;
|
---|
Note:
See
TracBrowser
for help on using the repository browser.