Salting the cabbage, carrot, and onion purges excess moisture that would otherwise turn the slaw into a soupy mess. Including sugar (another osmosis-inducing ingredient) balances the flavor. Limiting the purge to five minutes keeps the cabbage crunchy.