Tag LWC

Lightning Web Components Testing with Jest

Lightning Web Components (LWC) is a framework for building fast, reusable, and efficient web components for Salesforce. One of the key features of LWC is the ability to easily test your components using Jest, a popular JavaScript testing framework. In this blog post, we will go over the importance of writing Jest tests for lwc, installation steps for setting up Jest in your LWC project, as well as some code examples.

Top 10 Tips for Optimizing Lightning Web Component Development

Salesforce Lightning Web Components (LWC) is a modern, lightweight framework for building web applications on the Salesforce platform. LWC provides a set of reusable, high-performance web components that can be easily integrated into any Salesforce application. To get the most out of LWC, it's important to follow best practices to ensure that your components are efficient, maintainable, and easy to use.

LWC Conditional Rendering: lwc:if, lwc:elseif, lwc:else

As a developer, one of the most important aspects of building web applications is the ability to control the flow…

Using LWR to Build Custom Pages in Salesforce

Lightning Web Runtime (LWR) is a special feature of the Salesforce Lightning platform that allows developers to create custom pages…

LWC | Call External APIs from JavaScript

The Lightning Component framework uses Content Security Policy (CSP), a W3C standard, to control and restrict content loaded on a page to prevent cross-site scripting and other code injection attacks. The default CSP policy does not allow API calls from JavaScript code. To make API calls, a remote site needs to be added as a CSP Trusted Site in the Salesforce org. The article also provides a step-by-step guide to add a CSP trusted site and make an API call from JavaScript code successfully.