Package Exports
- @acoustic-content-sdk/react-hbs-edit
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@acoustic-content-sdk/react-hbs-edit) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Home > @acoustic-content-sdk/react-hbs-edit
react-hbs-edit package
Implementation of utility functions and react components that render the component based on handlebars templates and integrate with inline edit.
Functions
| Function | Description |
|---|---|
| createHandlebarsComponent(aStore, aDeliveryContent, aEditService, aDoc, aLogSvc, aScheduler) | Returns a React component that renders the content item passed into its properties. Markup elements annotated with inline edit controls will be registered with the inline edit service. |
Interfaces
| Interface | Description |
|---|---|
| HandlebarsComponentProps | Property interface of the handlebars components |
Variables
| Variable | Description |
|---|---|
| VERSION | Version and build number of the package |
Home > @acoustic-content-sdk/react-hbs-edit > createHandlebarsComponent
createHandlebarsComponent() function
Returns a React component that renders the content item passed into its properties. Markup elements annotated with inline edit controls will be registered with the inline edit service.
Signature:
export declare function createHandlebarsComponent(aStore: ReduxRootStore, aDeliveryContent: DeliveryContentResolver, aEditService: WchInlineEditServiceV2, aDoc: Document, aLogSvc?: LoggerService, aScheduler?: SchedulerLike): ReactComponent<HandlebarsComponentProps>;Parameters
| Parameter | Type | Description |
|---|---|---|
| aStore | ReduxRootStore |
the redux store that contains all metadata |
| aDeliveryContent | DeliveryContentResolver |
|
| aEditService | WchInlineEditServiceV2 |
the edit service |
| aDoc | Document |
the document, used to instantiate a template node |
| aLogSvc | LoggerService |
optionally a logger service |
| aScheduler | SchedulerLike |
optionally a scheduler |
Returns:
ReactComponent<HandlebarsComponentProps>
a component that renders a content item based on the handlebars templates from the redux store
Home > @acoustic-content-sdk/react-hbs-edit > HandlebarsComponentProps
HandlebarsComponentProps interface
Property interface of the handlebars components
Signature:
export interface HandlebarsComponentProps Properties
| Property | Type | Description |
|---|---|---|
| contentItemId | string |
ID of the item to render |
| layoutMode | string |
Optional layout mode |
Home > @acoustic-content-sdk/react-hbs-edit > VERSION
VERSION variable
Version and build number of the package
Signature:
VERSION: {
version: {
major: string;
minor: string;
patch: string;
branch: string;
};
build: Date;
}Home > @acoustic-content-sdk/react-hbs-edit > HandlebarsComponentProps > contentItemId
HandlebarsComponentProps.contentItemId property
ID of the item to render
Signature:
contentItemId?: string;Home > @acoustic-content-sdk/react-hbs-edit > HandlebarsComponentProps > layoutMode
HandlebarsComponentProps.layoutMode property
Optional layout mode
Signature:
[KEY_LAYOUT_MODE]?: string;