function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Sachin Bhalerao 17Sachin Bhalerao 17 

Unable to unserstand Lightning Web Component Code?

Dear Team ,

Greetings !!!

Through Trailhead i picked one example of Hello World in Lightning Web Component . This code is running and component is also created in App Builder but i am unable to unserstand the code . Would you plz let me understand how it works and what is the functionality of 

   @track greeting = 'World';
    changeHandler(event) {
        this.greeting =;

HTML Code:

    <lightning-card title="HelloWorld" icon-name="custom:custom14">
        <div class="slds-m-around_medium">
            <p>Hello, {greeting}!</p>
            <lightning-input label="Name" value={greeting} onchange={changeHandler}></lightning-input>


import { LightningElement, track } from 'lwc';
export default class HelloWorld extends LightningElement {
    @track greeting = 'World';
    changeHandler(event) {
        this.greeting =;


<?xml version="1.0" encoding="UTF-8"?>
<LightningComponentBundle xmlns="" fqn="helloWorld">

Thanks & Regards
Sachin Bhalerao
Nisar AhmadNisar Ahmad

You can try below link I hope it is helpful for you:
I hope you find the above solution helpful.