Hello World using LWC
1. Create Lightning Web Component 1️⃣ In VS Code, open the Command Palette by pressing Ctrl + Shift + P on Windows. 2️⃣ Type SFDX and select SFDX: Create Lightning Web Component . 3️⃣ Type helloWorldCMP as the name of the new component and press Enter. 4️⃣ Press Enter again to accept the default directory path: force-app/main/default/lwc . 2. helloWorldCMP.html Add the following code into the HTML file: <template> <lightning-card title="First LWC" icon-name="custom:custom14"> <p>Hello World!!</p> <p>Welcome {name}..</p> </lightning-card> </template> 1. <template> : Root element of an LWC component’s HTML template. 2. <lightning-card> : Lightning Base Component providing a styled card interface. 3. <p>Hello World!!</p> : Displays “Hello World!!” inside the card. 4. <p>Welcome {name}..</p> : ...










