availity-reactstrap-validation icon indicating copy to clipboard operation
availity-reactstrap-validation copied to clipboard

AvRadioGroup onChange behavior

Open KaseyPowers opened this issue 8 years ago • 2 comments

When adding the onChange event to an AvRadioGroup, it seems the function is called for every radio option, once with the selected value passed in correctly to the second argument, and the rest of the times with undefined.

I can understand why it acts this way, but I'm not sure if this should be the expected behavior?

KaseyPowers avatar Oct 24 '17 15:10 KaseyPowers

I'm experiencing the same behavior

diegodesouza avatar Mar 13 '20 18:03 diegodesouza

Greetings @KaseyPowers , @diegodesouza, I might be facing a similar problem. I am not satisfied by the "for every radio option" as mentioned by @KaseyPowers . Here is what I observe: If I log the times the event handler is called, I can see that it is been called twice for each radio option that I click. Now, KaseyPowers has stated that the second time event handler is being called with undefined if yes then, it might explain another error that I am facing.

If you guys have achieved an understanding for this behavior then, I request that you share the same with me.

Regards SNikhill

nikkhielseath avatar Dec 24 '20 21:12 nikkhielseath