Community · Lightning · LWC · Salesforce

PASS MULTIPLE PARAMETER TO LWC IN PUBLIC COMMUNITY PAGE WITH SIMPLE EXAMPLE

Create a LWC component TestCommunity. In TestCommunity.js-meta.xml, add the <target> and <property> tags as the example below and save the file. <?xml version="1.0" encoding="UTF-8"?> <LightningComponentBundle xmlns="http://soap.sforce.com/2006/04/metadata">     <apiVersion>50.0</apiVersion>     <isExposed>true</isExposed>     <targets>         <target>lightningCommunity__Page</target>         <target>lightningCommunity__Default</target>         <target>lightning__HomePage</target>     </targets>     <targetConfigs>         <targetConfig targets="lightningCommunity__Default">             <property name="recordId" type="String" label="Record ID" description="The value should be {!recordId}." />             <property name="taskId" type="String" label="Task ID" description="The value should be {!taskId}." />         </targetConfig>     </targetConfigs> </LightningComponentBundle> In TestCommunity.js file using @api annotation for recordId and taskId propoerty in js. import { LightningElement, api} from… Continue reading PASS MULTIPLE PARAMETER TO LWC IN PUBLIC COMMUNITY PAGE WITH SIMPLE EXAMPLE

Adminstrator · Lightning · LWC · Salesforce

LIGHTNING WEB COMPONENT

What is LWC? Lightning Web Components is the Salesforce implementation of that new breed of lightweight frameworks built on web standards. It leverages custom elements, templates, shadow DOM, decorators, modules, and other new language constructs available in ECMAScript 7 and beyond. How it Works? Lightning Web Components provides a layer of specialized Salesforce services on… Continue reading LIGHTNING WEB COMPONENT