ModuleConfig
Core configuration interface for the module system.
Interface Definition
lib
- Type:
boolean - Description: Specifies whether the current module is in pure library mode. When set to
true, the module will not automatically create default entry file exports (such assrc/entry.clientandsrc/entry.server).
Default Value: false
links
- Type:
Record<string, string> - Description: Module linking configuration, where the key is the remote module name and the value is the module build artifact directory path.
imports
- Type:
ModuleConfigImportMapping - Description: Module import mapping configuration, where the key is the local module identifier and the value is the remote module path. Supports environment-specific configuration.
scopes
- Type:
Record<string, ModuleConfigImportMapping> - Description: Module scope mapping configuration, where the key is the directory path prefix and the value is the import mapping configuration within that scope.
exports
- Type:
ModuleConfigExportExports - Description: Module export configuration. Supports multiple configuration formats.
Type Definitions
ModuleConfigImportMapping
Import mapping configuration type, supporting string and environment-specific configurations.
ModuleConfigExportExports
Export configuration array type, supporting mixed arrays of strings and export objects.
ModuleConfigExportExport
Export configuration item type, supporting both string and export object formats.
ModuleConfigExportObject
Export object configuration type, where the key is the export name and the value is the export configuration value.
ModuleConfigExportObjectValue
Export configuration value type, supporting string and environment-specific configurations.
BuildEnvironment
Build target environment type.
Parsed Interfaces
ParsedModuleConfig
lib
- Type:
boolean - Description: Whether the current module is in pure library mode.
ParsedModuleConfigEnvironment
ParsedModuleConfigLink
ParsedModuleConfigExports
Parsed export configuration record type, where the key is the export name and the value is the export configuration object.