Snap is a packaging format developed by canonical to use in Ubuntu and other Linux distros but there are problems with snaps as they are slow compared to native binaries and consume a lot of disk space and the server side of snapcraft is proprietary, but since it’s their own technology canonical is pushing it too much over other solutions in Ubuntu, so for any of the following reasons if you want to uninstall snaps from your system just follow along.
Run the following command to list all snaps in your system.
Then remove snaps one by one by using the following command
sudo snap remove --purge snap-name
After removing snaps you can completely remove snap by using the following command
sudo apt remove --purge snapd
Delete snap cache
Run the following commands to remove any snap configuration or cache files.
sudo rm -rf /var/cache/snapd/
rm -fr ~/snap # for home user
sudo rm -fr ~/snap # for root user
Hold snap package
Run the following command to prevent snap from auto installing, for example, while installing the chromium package.