this is my first post and i hope i am in the right section here. Also, i am very new to p5 and coding in general so please bear with me
i am kind of stuck in a very simple project i’m doing. i want to drag the canvas out of the browser into my desktop and be saved as a specific file (svg in my case, i use the P5js-svg plugin). i haven’t found a solution for this i thought i’d ask here.
i thought i’d note that, when i make my canvas a variable and make it a div element
then it returns the following in my console:
TypeError: Argument 1 ('node') to Node.appendChild must be an instance of Node
if i set my canvas as normal (non-svg) the div element works fine (i hope i’m right about it being called a “div element”). But i still have no idea how to make it a “drag-able” image/file, this should at least be doable since i can drag out any image from another source, say a png image on a website.
shall i post my file or do you need any additional information?
thanks in advance and please apologize if i made any obvious mistakes, i’m learning