Saturday, December 28, 2019

Lightning Web Component Bundle

LWC bundle contains an HTML file, a JavaScript file, and a metadata configuration file as shown in the below image and these files are created once we create a Lightning web component.


Lightning Web Component Bundle


HTML FILE:

The HTML file is enclosed within the <template> tags.  It contains the component HTML.


LWC bundle


JAVASCRIPT FILE:

A sample javascript file is shown in the below image.

LWC bundle


Metadata configuration file:

A sample metadata configuration file is shown in the below image.


Lightning Web Component Bundle


We can also create a .css file for styling purpose as shown in the below image. We can also create svg file for purpose of displaying icon.

Lightning Web Component Bundle

No comments:

Post a Comment