SolidJSS
SolidJSโ€ข3y ago
romanobro

vanilla js in onMount?

I got help recently about finding a way to import a vanilla javascript file as an independent source supportusing vanilla js with import?

and It worked on the initial load, but using the back button would cause many problems.

Now, I have moved to putting lots of plain js in an onMount, which is working well so far, but seems like a bad idea. Does anyone know of any issues that could be caused by that method?

to clarify, I am using a library (d3), interacting with dom elements, and using setTimeout to make a recursive call to update a slideshow. This makes it seem to me as if the onMount call never ends. Will that create an issue?
Was this page helpful?