Learners often found themselves needing to navigate away from the curriculum page (on which the widget was embedded) and come back to it later; or they found themselves needing to reload the page for some reason (perhaps that was how they wanted to "restart" their sketch?). They then became frustrated when they found that the code they'd entered was no longer in the widget. So it might be useful to store the current code in sessionStorage and bring it back on page load.
As mentioned in #26: