I shave before my shower.
I always use plenty of moisturizer afterwards and never have a problem with scalp irritation. Often right after a shave I'll apply a little bit of mineral oil (which is just baby oil without the fragrance added) to my scalp and then run the razor over my dome again. Then into the shower. I'm not sure the mineral oil doesn't wear down the blades but, after my shower, my scalp is smooth and VERY soft. That sure gets me a lot of attention (some of the attention is unwanted, but, what can you do?).