Just remember, any game that requires patches will not be able to get patches after the switch loses support from Nintendo
So you own the physical cartridge but the patches that were (in some cases) required to make the game work will be unable to be downloaded in the future
This is why I support modding consoles, that way I can continue to have a fully functional console long into the future
A great example of a past Nintendo console that no longer has support but is online enabled is the 3DS.
Pokemon X and Y had a game breaking bug on launch that if not patched means that there's a whole chunk of the game that of you save in that location the game save corrupts, now that online support is gone you can no longer get the patch that fixes the bug.
So if you got a copy of Pokemon X or Y and a 3DS today, you'd never be able to get the patch.
Nintendo, to date, has never shut down the CDN for any console. You can still redownload titles purchased on the Wii Shop Channel, for example. This means that you would be able to download updates for Pokémon X and Y or any other 3DS game.
Not all carts ship with version 1.0, but all versions that shipped with 1.0 will stay at 1.0.
For example:
Breath of the Wild is on version 1.3.1, if you have a cart from launch it will still be on the older version and the console will prompt you for an update. But without online functionality those updates will be impossible to get.
Technically, there one other option, the switch allows for updating via local updates. Youd just need another user who has the update installed nearby.
DLC and bug fixes are downloaded as patches, once online support is gone you won't be able to download that stuff again. So if you buy a second hand cart after online is gone or you uninstall the game data after online is gone there's no getting that back. It's gone without a modded console.
For example:
Breath of the Wild is on version 1.3.1, all changes since the version on the cart you have will be impossible to get once online functionality is gone.