[F] getClientNamespace
function getClientNamespace(context, entity): string;Returns the client namespace for a given entity. The order of operations is as follows:
- If
@clientNamespaceis applied to the entity, this wins out. a. If the--namespaceflag is passed in during generation, we will replace the root of the client namespace with the flag. - If the
--namespaceflag is passed in, we treat that as the only namespace in the entire spec, and return that namespace. - We return the namespace of the entity retrieved from the original spec.
Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
context | TCGCContext | |
entity | Enum | Interface | Model | Namespace | Union |
Returns
Section titled “Returns”string