Use a device that’s mass produced enough it can’t be targeted e.g a MacBook, then keep it airgapped and don’t do normal computing on it.
airgapped pre crypto devices are extra safe: break out the ti82! don’t buy a ti82 for this purpose, it has to be one you had in your closet. If a blog post describes how to code it in TiBasic then affiliate links a calculator in ebay, well…
Hardware wallets are air-gapped. The issue here was a distributor got acquired and then snuck a chip in that could read the spi link between the microcontroller and the screen. The chip had its own cellular modem and could send the passphrase that was shown on the screen to the attackers.