MCPcopy
hub / github.com/webpack/webpack / createDependency

Method createDependency

lib/EntryPlugin.js:62–72  ·  lib/EntryPlugin.js::EntryPlugin.createDependency

* Creates a dependency. * @param {string} entry entry request * @param {EntryOptions | string} options entry options (passing string is deprecated) * @returns {EntryDependency} the dependency

(entry, options)

Source from the content-addressed store, hash-verified

60 * @returns {EntryDependency} the dependency
61 */
62 static createDependency(entry, options) {
63 const dep = new EntryDependency(entry);
64 class="cm">// TODO webpack 6 remove string option
65 dep.loc = {
66 name:
67 typeof options === class="st">"object"
68 ? /** @type {string} */ (options.name)
69 : options
70 };
71 return dep;
72 }
73}
74
75module.exports = EntryPlugin;

Callers 3

applyMethod · 0.80
applyMethod · 0.80
applyMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected