0

I think this is a very dumb question sorry for this I am just doing some POC.

here is the code:

  <lightning-radio-group 
        name="radioGroup"
        label="Radio Group"
        options={options}
        value={value}
        required
        type="radio">
    </lightning-radio-group>

 <lightning-button 
        variant="base" 
        label="Base" 
        title="Looks like a link" 
        onclick={handleClick} 
        class="slds-m-left_x-small">
    </lightning-button>

JS.

@track value;

get options() {
    return [
        { label: 'op1', value: 'op1' },
        { label: 'op2', value: 'op2' },
    ];
}

handleClick(event) {
    console.log(this.value);
}

The Console log is displaying me undefined...

2

0

Browse other questions tagged .