Cleaning cloth diapers?

Taylor
So I plan on using cloth diapers but I'm unsure of how to clean them. Like do I need to spray them out right after changing baby and then wash them or what?