Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.
Create Components for LWR Sites
If you previously created Lightning web components for Experience Builder sites, you’re familiar with the lightningCommunity__Page and lightningCommunity__Default targets. For the LWR template, we added two new target types—lightningCommunity__Page_Layout and lightningCommunity__Theme_Layout.
| Target Value | Description |
|---|---|
| lightningCommunity__Page | Enables a drag-and-drop component to be used on an LWR or Aura site page in Experience Builder. Components appear in the Components panel. |
| lightningCommunity__Page_Layout | Enables a component to be used as a page layout in an LWR site in Experience Builder. Components appear in the Page Layout window. |
| lightningCommunity__Theme_Layout | Enables a component to be used as a theme layout in an LWR site in Experience Builder. Components appear in Settings in the Theme area. |
| lightningCommunity__Default |
Used together with lightningCommunity__Page or lightningCommunity__Theme_Layout. Enables a component to expose properties that are editable when the component is selected in Experience Builder. For Experience Builder sites, only lightningCommunity__Default supports configurable component properties. We support these property attribute data types:
|
- To make your component usable in Experience Builder, set isExposed to true, and define lightningCommunity__Page, lightningCommunity__Page_Layout, or lightningCommunity__Theme_Layout in targets.
- To include properties that are editable when the component is selected in Experience Builder, define lightningCommunity__Default in targets and define the properties in targetConfigs.