Everyone probably knows this, but characters holding items (like Link with a bomb or Diddy with a banana) can do a side smash while holding the item.
When you press A to pick up the item, hold A down instead. Then just press C-stick side to do a smash, and let go of A to stop charging it. If you forgot to hold A when you pick up the item, you can always just roll or sidestep, and then hold A.