Spot the Signs. Do you have a good relationship with your manager? Is he or she relatively reasonable? Do you have regular one_on_ones where you talk about your career goals and growth? If so, it's likely that your boss will accept your resignation with grace, help develop a plan of action for your last two weeks, and maybe even attend your farewell happy hour.
What Else Should I Do When Resigning? First, out of respect and common courtesy, you would ideally tell your manager in person that you are resigning. If you can't wait for that or work remotely or some other complication prevents that, the telephone is the next best option. You can choose to follow up or accompany that discussion with a formal letter of resignation afterwards, but it would be a rare workplace that would require that formality.