0

There is a lightning input element in the body of a tab of my custom standalone app and I would like to have any values in the input element cleared once I move to another tab or any other part of the application. Since there is only an onactive but no "inactive" attribute for a tab, is there a workaround for achieving this? Any advice or help would be greatly appreciated.

2
  • If you are using lightning:tabset then you can try to use` onselect` method of the tabset. Here you can apply your logic in case of tab switch.
    – Saroj Bera
    Sep 27, 2019 at 6:08
  • I actually tried doing this as well but in the case where I have tabsets nested within other tabsets and the tab of interest is in the innermost nest, I will have to use multiple onselect methods and attributes to accomplish the task. I was hoping that there was a way of working on just the one tab of interest but if there is no workaround, I guess I will have to do it the long way.
    – user73893
    Sep 27, 2019 at 6:54

0

You must log in to answer this question.

Browse other questions tagged .