"Using non-approved or poorly rated cables might damage the Switch or prevent it from receiving sufficient power, Nintendo of Japan warns."
Not all USB-C cords are made the same. An Ars Technica article recommends Nintendo Switch users be extra careful about third-party USB-C cables and accessories, noting that poorly-made ones could lead to dead hardware or longer-than-necessary charging times. Read more here.
Make sure to check out ZMI's USB-C cables. They come with the required 56K ohm resistor and will work great when charging up your Switch!