A simple plugin wrapper to manage state via cookies