'Sometimes life cycle hooks run twice and sometime run once when the component is load why is that?

Explanation:- I made an Lwc component for quick action and put it on a record detail page, In the Lwc component, I made all life Cycle hooks and wire methods with debug log in them. So, when I clicked the quick action button methods run twice, and when I put this same component on a different object it just run once.

So, my question is why these methods run differently.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source