Now, if only all of these titles could make it to the Switch eShop, that'd be swell. It's sad to see the Nintendo 3DS and the Nintendo Wii U go, but at least Nintendo gives the players a little more time to stock up on games before they're cut off for good. Applies to: Nintendo Switch Family, Nintendo Switch, Nintendo Switch Lite, Nintendo Switch - OLED Model, Nintendo Account. However, alongside the eShop, it will also shut down the StreetPass Mii Plaza, Theme Shop, and Nintendo Badge Arcade. The company's also not planning to take down online play on either of the consoles.
Nintendo promises that "for the foreseeable future," it will still allow you to re-download previously purchased games and DLCs, as well as required software updates. In all likelihood, you run no risk of wasting money as long as you combine your Network ID with the new account. Once the 3DS/Wii U eShop closes down, the balance will remain usable for the Nintendo Switch.
If you link your older-generation Nintendo Network ID wallet with your Nintendo Account (used for the Nintendo Switch), you'll be able to combine the balance of both shops and use it toward buying games on any of your systems.