I’ve known for a while that Observable automatically generates a thumbnail for a notebook based on the first image/dataviz in that notebook. For the most part, the algorithm is terrific!
But once in a while errors like the one below come up, even though everything still works fine if I open the notebook. I’d love to know why this is happening and what steps I can take to avoid it!
I’m not sure what’s going on; I suppose the auto preview generator is trying to render the preview prior to your async functions completion of their task.
An easy work around is to set the preview image manually, which you can do from your notebooks tab:
The reason for the error is that you’re using a relatively new JavaScript language feature (string.replaceAll) that isn’t supported in all browsers, including our thumbnailer.