Framework updates
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
19
node_modules/webpack/lib/sharing/ConsumeSharedModule.js
generated
vendored
19
node_modules/webpack/lib/sharing/ConsumeSharedModule.js
generated
vendored
@@ -8,7 +8,10 @@
|
||||
const { RawSource } = require("webpack-sources");
|
||||
const AsyncDependenciesBlock = require("../AsyncDependenciesBlock");
|
||||
const Module = require("../Module");
|
||||
const { CONSUME_SHARED_TYPES } = require("../ModuleSourceTypeConstants");
|
||||
const {
|
||||
CONSUME_SHARED_TYPES,
|
||||
JAVASCRIPT_TYPES
|
||||
} = require("../ModuleSourceTypeConstants");
|
||||
const {
|
||||
WEBPACK_MODULE_TYPE_CONSUME_SHARED_MODULE
|
||||
} = require("../ModuleTypeConstants");
|
||||
@@ -41,6 +44,7 @@ const fallbackModuleCache = new WeakMap();
|
||||
/** @typedef {import("../util/Hash")} Hash */
|
||||
/** @typedef {import("../util/fs").InputFileSystem} InputFileSystem */
|
||||
/** @typedef {import("../util/semver").SemVerRange} SemVerRange */
|
||||
/** @typedef {import("../Module").BasicSourceTypes} BasicSourceTypes */
|
||||
|
||||
/**
|
||||
* @typedef {object} ConsumeOptions
|
||||
@@ -159,6 +163,19 @@ class ConsumeSharedModule extends Module {
|
||||
return CONSUME_SHARED_TYPES;
|
||||
}
|
||||
|
||||
/**
|
||||
* Basic source types are high-level categories like javascript, css, webassembly, etc.
|
||||
* We only have built-in knowledge about the javascript basic type here; other basic types may be
|
||||
* added or changed over time by generators and do not need to be handled or detected here.
|
||||
*
|
||||
* Some modules, e.g. RemoteModule, may return non-basic source types like "remote" and "share-init"
|
||||
* from getSourceTypes(), but their generated output is still JavaScript, i.e. their basic type is JS.
|
||||
* @returns {BasicSourceTypes} types available (do not mutate)
|
||||
*/
|
||||
getSourceBasicTypes() {
|
||||
return JAVASCRIPT_TYPES;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {ModuleGraph} moduleGraph the module graph
|
||||
* @returns {Module | null} fallback module
|
||||
|
||||
Reference in New Issue
Block a user