5 Must-Know Spring ’21 Enhancements for Experience Cloud and CMS
After a COVID-delayed Winter ‘21 release, Salesforce is back on track to deliver its Spring ‘21 according to plan. This means that the majority of orgs will be seeing the updates the weekend of February 12/13, 2021.
Add Salesforce CMS Content to Custom Lightning Web Components
Phil’s Quick Take (How will this help me?): If you have built or want to build custom components that use or display content, this will allow your end user to upload or select content via clicks.
Salesforce Summary: Readily add Salesforce CMS content to Experience Builder sites using custom Lightning web components. After you publish content in a CMS workspace, you can enhance any custom component with your content repositories at the click of a button.
ContentReference property type in .js-meta.xml file for custom component.
Configure CMS content for a custom Lightning web component by specifying type=”ContentReference” for the component property type in the .js-meta.xml file. You can also configure your component to filter for a specific content type. For example, to display only published images from your CMS workspace, specify filter=”cms_image”, as shown:
<property type=”ContentReference” name=”contentId” label=”Content ID” filter=”cms_image”/>
In Experience Builder, add the component to the page and click Add Content in the component’s properties. Add images, documents, news articles, and more directly to your site from your CMS workspace.
Lightning Message Service Now Supported in Experience Cloud (Beta)
Phil’s Quick Take (How will this help me?): Do you have a mix of Visualforce, Aura, and Lightning Web Components? This will aid communication between those different elements within an Experience (Community)
Salesforce Summary: Use Lightning message service to communicate across the Document Object Model (DOM) within an Experience Builder site page. Communicate between Aura and Lightning web components in Experience Builder site pages.
See this page for more information: Lightning Message Service
lightning:navigation in Aura Sites Now Supports generateUrl with More actionNames
Phil’s Quick Take (How will this help me?): This provides more flexibility for navigation within custom Aura components in a Salesforce experience. Dynamically send users to new, edit, or clone pages for a particular record.
Salesforce Summary: The lightning:navigation component now supports generateURL using a pageReference with the New, Edit, and Clone actionNames. Previously, only the View actionName was supported. Standard record pages with edit and clone actions and standard object pages with a new action now return a URL that can be used to navigate to the action specified by the pageReference. The behavior of the navigate call using lightning:navigation hasn’t changed.
Keep Things Consistent with Content Key
Phil’s Quick Take (How will this help me?): If you are using CMS content and moving it between different orgs (note: see the next feature, as it is related), you can now uniquely identify your content anywhere. The new Content Key is unique across all of Salesforce.
Salesforce Summary: Your Salesforce CMS content now has a content key. This unique identifier sticks with your content no matter the version and across Salesforce orgs, sites, and components. Use the content key to deploy content between orgs, such as sandbox to production, with export and import JSON files in .zip archives.
When you add new content to a Salesforce CMS workspace, we automatically assign a content key that sticks with that content as it’s updated and versioned.
Deploy CMS Content and Components from Sandbox to Production
Phil’s Quick Take (How will this help me?): If you are using content, why not sync it across production and sandboxes? Now, you can use the Content Key (see previous feature) to export and import your content with ease.
Salesforce Summary: Now you can use the content key to export content from sandbox and import it to production. Then deploy single item components with the experience bundle from sandbox to production. Previously, you recreated your content when you moved CMS components from sandbox to production.
To move your content, first export content from your Salesforce CMS workspace, and then import the content into Salesforce CMS.
You can find the full lists of Experience Cloud and CMS features here:
Enjoy the Spring ’21 release! Reach out if you have any thoughts or questions! firstname.lastname@example.org
Phil Weinmeister is the VP of Product Management at 7Summits. He is a Salesforce MVP with 20 certifications and has authored three books that guide readers through leveraging Salesforce in their digital solutions.