Credit to Shiggy:
NoE seems to have stricter guidelines. Boxart has a big "microSD card required" notice, plus the box also mentions the download size in the note on top.
Credit to Pokemaniac for finding the following from NoA's support site:
On the eShop, the page for NBA 2K18 lists 22.9GB required space. Here, the initial software download hints at how big the physical game will be, 6.8GB. How is that the case? There would be no need for segmented download files unless 2K decided they weren't going to fit 22.9GB onto a 32GB game card due to costs currently.
A microSD card (sold separately) is required to download NBA 2K18 for Nintendo Switch, in addition to 5GB per save file on the system memory. Please have the microSD card inserted before beginning the game download and ensure that you have a least 5GB of system memory (not on a microSD card) available.
Below are the storage space requirements:
Initial software download after purchase – 6.8 GB
Additional software update – 16.1 GB
Save file – 5 GB system memory per save file
Please note that a microSD card is required for both the digital and physical versions of the game. Additional information about this requirement is located on the game packaging and in the Nintendo eShop / Game Store.
Also, don't forget that you'll need 5GB of space for save data in the internal storage.