Getting Started with Lightning Web Component

Before starting with Lightning Web Component, I would suggest to read this introduction post first.

If you enjoy watching video then you might enjoy below video where I conducted Live coding explaining basics of Lightning Web Component.

In this post, we are going to Show loading image on initial load of LWC. In background we would be calling Apex class to take decision if loading image should be hided or redirect user to some other page.

Continue reading “Getting Started with Lightning Web Component”

Introduction to HTML Web Components

Pillars of HTML Vanilla Web Components

Modern browsers have become so advanced and powerful that there is almost no or minimal need of Javascript libraries these days. There was time when web developers rely heavily on frameworks like JQuery, Angular or React. Same for Salesforce, when it launched Aura framework in 2014.

In last 5 years, web browsers have evolved so much that we need to revisit and check ourselves that do we really need libraries or frameworks for every small functionalities ? Considering rich feature set browsers, Salesforce already revisited aura framework and decided that it’s time to make it more lightweight and use native browser capabilities as much as possible. Welcome Lightning Web Components !!! Before we jump into ocean of Lightning Web Components, it’s important to understand what is supported by browsers natively ? Out of many features supported by modern browsers, one of most important one is Web Component.

Below are 4 pillars of Web Components

  1. Templates
  2. Custom Element
  3. Shadow DOM
  4. Imports
Continue reading “Introduction to HTML Web Components”