Open toolness opened 8 years ago
Does the preview pane resize with based on size defined in setup? I check the documentation at https://toolness.github.io/p5.js-widget/
Question: Is it possible to specify the width of the preview to be 50% of the container?
Kf
It shouldn't be hard to hook in to calls to
createCanvas
and resize the preview pane based on its dimensions. Or just hook intoresize
DOM events and do the same.The slightly harder part is figuring out what to do with the edge cases, e.g. if the sketch decides to call
createCanvas(20000, 20000)
but the page is only 800px wide.