matplotlib / mpl-brochure-site

Source for the top-level landing page.
Other
3 stars 13 forks source link

gh-pages and script.js #32

Closed jklymak closed 2 years ago

jklymak commented 2 years ago

@QuLogic, or anyone else who well-understands js can you post-facto review the changes I made to https://github.com/matplotlib/mpl-brochure-site/blob/main/docs/_static/script.js It seems that on gh-pages window.addEventListener was not getting called (or not getting called soon enough) so the new image-rotator was not showing up. In the neve version I moved it to document.addEventListener and it seems to now work.

I tried this after looking at https://stackoverflow.com/questions/48516736/javascript-working-locally-but-not-on-github-pages-site

Sorry for the PR thrash - I figure the landing site is not really "live" yet, so I can be forgiven a bit of hacking. Naturally when this starts getting uploaded to the real site I won't hack like this. But I couldn't reproduce the error locally, nor at the circle redirect...

QuLogic commented 2 years ago

That seems good to me, and seems to be about what the problem probably is.