The issue specifically arises when using third-party chargers and/or docks with the system docked. In docked mode, the Switch draws more power than when undocked, and requests an amount of power which is not the same as the amount of power that it actually expects, or that is delivered by the first-party charger and dock. This can result in bricking your system.
In short, the Switch does not properly implement the USB-PD standard.