You need to sign in to do that
Don't have an account?
Nerdy
Conditionnal markup to make a field required
Hello,
I need your help to achieve this conditionnal markup in a lightning form :
I want to make a text input mandatory whenever the user checks Yes on another radio-group input :
I need your help to achieve this conditionnal markup in a lightning form :
I want to make a text input mandatory whenever the user checks Yes on another radio-group input :
<div class="slds-col slds-size_1-of-2"> <lightning:radioGroup name=" " options="{! v.yesNo }" value="{! v.account.firstField}" type="radio" /> </div> <div class="slds-col slds-size_1-of-2"> <lightning:input name=" " label="Label2" value="{!v.account.secondField}" /> </div>
try something like below, When you set the "inputRequired" value inside the controller.js, then the input field get rerender.
regards