Disappearing Desktop icons
My desktop icons inadvertently disappeared from my desktop. No amount of clicking, ticking, or checking would bring them back, so the easy fix of Finder preferences was out. Logging in under a different account showed icons were on the Desktop. Restarting the computer didn't do anything to help. Additionally, clicking on the Desktop would not make the Finder window active; force-quitting the Finder had no effect.
What did have an effect was a terminal command I stumbled upon by accident. I'm posting it here in the hopes it saves someone else the time and aggravation I spent trying to find an answer on how to get their icons to show on the Desktop again. Good luck!
% defaults write com.apple.finder CreateDesktop -bool true
% killall Finder
Mac mini, macOS 11.5