If you quit instead of being fired, you can avoid explaining your dismissal to potential employers. When you submit your resignation, you have the opportunity to present your decision to leave in a positive light.
On the other hand, there are advantages to being let go. For performance or qualify for unemployment benefits, you must first have been fired.