Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Type aliases

Functions

Type aliases

lazyMapFunction

lazyMapFunction: () => Promise<unknown>

Type declaration

    • (): Promise<unknown>
    • Returns Promise<unknown>

Functions

Const LazyMapTo

  • LazyMapTo(resourceTypes: string | string[]): (lazyPromise: lazyMapFunction) => void
  • Use to register resource types to Class mapping in a lazyLoad fashion, with dynamic imports

    Example:

    import { LazyMapTo } from '@adobe/aem-spa-component-mapping';
    
    MyComponent.ts:
    export class MyComponent {
     ...
    }
    
    LazyMapTo('my/resource/type')(MyComponent);
    

    Parameters

    • resourceTypes: string | string[]

      AEM resource type(s).

    Returns (lazyPromise: lazyMapFunction) => void

    Function mapping a class with the given resource types.

Const MapTo

  • MapTo(resourceTypes: string | string[]): (clazz: unknown) => void
  • Use to register resource types to Class mapping.

    Example:

    import { MapTo } from '@adobe/aem-spa-component-mapping';
    
    class MyComponent {
     ...
    }
    
    export default MapTo('my/resource/type')(MyComponent);
    

    Parameters

    • resourceTypes: string | string[]

      AEM resource type(s).

    Returns (clazz: unknown) => void

    Function mapping a class with the given resource types.

      • (clazz: unknown): void
      • Parameters

        • clazz: unknown

        Returns void

Generated using TypeDoc