Separated code for state, Flash, and deprecation.
Includes deprecation warning console messages.