Interface Config
isConfig(
config: unknown,
options?: { raiseException?: boolean },
): config is
| Dynamic<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>
| Standard<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>;
isConfigEmbed(
config: unknown,
options?: { raiseException?: boolean },
): config is Embed<SvelteComponent<any, any, any>, { PropsOmit: never }>;
parseConfig(
config:
| Dynamic<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>
| Standard<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>,
options?: { thisArg?: unknown },
): Parsed;
}
Index
Methods
Methods
isConfig
- isConfig(
config: unknown,
options?: { raiseException?: boolean },
): config is
| Dynamic<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>
| Standard<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>Parameters
- config: unknown
The potential config object to validate.
Optionaloptions: { raiseException?: boolean }Options.
OptionalraiseException?: booleanIf validation fails raise an exception.
Returns config is
| Dynamic<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>
| Standard<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>Is the config a valid TJSSvelte.Config.Dynamic or TJSSvelte.Config.Standard configuration object.
- config: unknown
isConfigEmbed
- isConfigEmbed(
config: unknown,
options?: { raiseException?: boolean },
): config is Embed<SvelteComponent<any, any, any>, { PropsOmit: never }>Validates
configargument whether it is a valid TJSSvelte.Config.Embed configuration object suitable for directly mounting via the<svelte:component>directive.Parameters
- config: unknown
The potential config object to validate.
Optionaloptions: { raiseException?: boolean }Options.
OptionalraiseException?: booleanIf validation fails raise an exception.
Returns config is Embed<SvelteComponent<any, any, any>, { PropsOmit: never }>
Is the config a valid TJSSvelte.Config.Embed configuration object.
- config: unknown
parseConfig
- parseConfig(
config:
| Dynamic<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>
| Standard<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>,
options?: { thisArg?: unknown },
): ParsedParses a TyphonJS Svelte dynamic or standard config object ensuring that the class specified is a Svelte component, loads any dynamic defined
contextorpropspreparing the config object for loading into the Svelte component.Parameters
- config:
| Dynamic<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>
| Standard<
SvelteComponent<any, any, any>,
{ ContextOmit: never; ContextShape: {}; PropsOmit: never },
>Svelte config object.
Optionaloptions: { thisArg?: unknown }Options.
OptionalthisArg?: unknownThisreference to set for invoking anycontextorpropsdefined as functions for Config.Dynamic configuration objects.
Returns Parsed
The processed Svelte config object turned with parsed
props&contextconverted into the format supported by Svelte. - config:
Validates
configargument whether it is a valid TJSSvelte.Config.Dynamic or TJSSvelte.Config.Standard configuration object suitable for parsing by TJSSvelte.API.Config.parseConfig.