Open
Description
I'm trying to use Plot.auto()
in a Server Side Rendering (SSR) environment, so using JSDOM to provide a DOM document. When plot()
is called, I get a TypeError.
I can't find much information on this, but I believe it might be to do with different instances of window being used. If I specify the mark type, e.g. Plot.rectY
it works fine, so think that this might be down to the mark type that auto is choosing based on the data, so no doubt I'll find other instances of marks that fail in this way.
const { document } = new JSDOM('<!DOCTYPE html>').window;
const plot = Plot.auto(penguins, {x: "island"}).plot({document})