Make API that allows users to persist widget state easily.