简体   繁体   中英

Javascript - changes are made after resizing window browser

I have got infinity scroll plugin on my website. After reaching the bottom I get new products which are as intended. The issue is that some content like "add-to-cart" or "product-price" are not displaying as it should be. For example, there is margins and padding set via js.

I thought that maybe if I bind this js with body element this may work, but I cannot find js that make those changes. (its Magento website)

This is only happening in products that were loaded through infinity plugin. After resizing window everything gets fine.

Why is this happening? Any help is appreciated

search for something like

  • ".addEventListener('resize'"
  • ".resize("
  • ".on( "resize"

in firebug's script tab, you may find the eventlistener method and see what happens when it gets fixed when you resize the page.

generally you will have to provide some more information.anything else is guessing

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM