Plugin Configuration Structure Overview
The plugin configuration is defined by several TypeScript interfaces that structure the entire configuration system. Below is an overview of each type and its purpose:
ArchitectureConfigJson
The root object for the architectural configuration.
version
: Configuration version.components
: Dictionary of component configurations, keyed by component type.
ConfigJsonAddons
Additional settings for configuration, typically used for template generation or metadata.
meta
: Metadata associated with the component.
ComponentConfigJson
Root configuration for a specific component type within the architecture.
root
: Root directory for this type of component.type
: General type categorization.name_pattern
: Naming pattern for the component.path_pattern
: File path pattern.element_type
: The kind of element (e.g., class, interface).defaults
: Default configurations for different scenarios.
ParamJson
Defines parameters for methods and constructors.
name
: Name of the parameter.type
: Data type of the parameter.access
: Access level (e.g.,public
,private
).is_optional
: Specifies if the parameter is optional.is_readonly
: Marks the parameter as read-only.value
: Default value of the parameter.
MethodJson
Describes methods within classes or interfaces.
access
: Access level of the method.name
: Name of the method.return_type
: Return type of the method.is_async
: Specifies if the method is asynchronous.is_static
: Defines whether the method is static.params
: List of parameters (can be a mix ofParamJson
andstring
).body
: The body code of the method.supr
: A super method (used for overriding).generics
: Generic types used by the method.prompt
: A prompt or description of the method.
ImportJson
Outlines the import requirements for a file.
dflt
: Default import name.path
: Path to the module or file.list
: List of named imports.alias
: Alias for the imported module.ref_path
: Reference path for the import (optional).
PropJson
Details properties within a class or interface.
name
: Name of the property.type
: Data type of the property.access
: Access level of the property.is_optional
: Indicates if the property is optional.is_readonly
: Marks the property as read-only.is_static
: Defines whether the property is static.value
: Default value of the property.
GenericJson
Defines a generic type and its constraints.
name
: Name of the generic type.inheritance
: Constraints (e.g.,extends
).dflt
: Default type if none is provided.
InheritanceJson
Describes inheritance for classes and interfaces.
generics
: List of generic types.name
: Name of the base class or interface.
ExportJson
Controls export settings of components.
is_default
: Marks the export as default.use_wildcard
: Allows for wildcard exporting.path
: Path to the module or file being exported.list
: List of named exports.alias
: Alias for the export.
FunctionJson
Represents a standalone function.
exp
: Export information.name
: Function name.return_type
: Return type of the function.is_async
: Indicates if the function is asynchronous.params
: Function parameters.body
: Body of the function.generics
: Generic types used by the function.
InterfaceJson
Describes an interface.
exp
: Export information.inheritance
: Inheritance information.props
: Properties of the interface.methods
: Methods within the interface.generics
: Generic types.imports
: Required imports.name
: Name of the interface.id
: Unique identifier (optional).
ConstructorJson
Defines a constructor for a class.
access
: Access level.params
: List of parameters.body
: Constructor body.supr
: Super constructor (if extending a class).
This structure provides a comprehensive system for configuring the generation and structure of code within a SoapJS project, aligning with the principles of Clean Architecture.
Last updated