Here's how you want to do it!
https://www.youtube.com/watch?v=5PJt0DXdZ0k
No, but seriously. Letter to the CP, hand delivered, left in inbox, or mailed. Give them at least the proper two weeks notice. Keep it simple, no rants, no tear-downs, etc. If they want to know why you are headed out, they will ask in the exit interview.
Smile, shake hands, and be on your way. That's how I did it.