Use @wire to define the getRecord Lightning Data Service wire adapter to gain access to raw record data so that you may apply business logic or design a form that…
Tag: Lightning web components

Mobile-Friendly Components
Making your Lightning web components mobile-friendly can help you reach a wider audience as more Salesforce users do business on their phones. Although there’s a chance that a component you…

Handling Events
The HTML template for the component can be used declaratively to listen for events, or programmatically using an imperative JavaScript API. Since less code needs to be written, it is…

Construct and Send Events
In the JavaScript class for a component, create and dispatch events. Use the CustomEvent() function Object() { [native code] } to create an event. Call the EventTarget.dispatchEvent() function to dispatch…

Pass Data in an Event
Set a detail property in the CustomEvent function Object() { [native code] } to send data to a receiving component. The event listener’s handler function provides access to the data…

Lifecycle Hooks pt. 2
Flowing from parent to child are both hooks. Because they are not yet created, child components cannot be accessed from callbacks. Use this to gain access to the host element.…