Menu icon Foundation
Is Reflow For ALL JavaScript

Hi

This maybe help with another issue I'm having on another website too (http://foundation.zurb.com/forum/posts/21727-issue-tabs-loading-javascript).

Both sites use JavaScript to display something. After the pages fully loads the disqus area overlays on the text. I'm thinking this is something to do with the data-equalizer not re-growing. The information called "Tags" should be above the footer and the grey links. Once you've scrolled to the bottom of the page and THEN refresh it re-flows correctly. I need the page to load and the two divs grow once the disqus script has loaded. Is there a way of doing this. Say getting data-equalizer to run again?

I've added the code to initiate reflow, but it hasn't helped.

Both sites need to check for additional JavaScript once the page has loaded or a Foundation JS script has run, such as changing the tabs or setting the height of a data-equalizered div.

Any ideas please?
G

(document).foundation('reflow')       

Wds grabs 2015 01 08 at 10.24.40

Reflowdisqusdata-equalizer

Hi

This maybe help with another issue I'm having on another website too (http://foundation.zurb.com/forum/posts/21727-issue-tabs-loading-javascript).

Both sites use JavaScript to display something. After the pages fully loads the disqus area overlays on the text. I'm thinking this is something to do with the data-equalizer not re-growing. The information called "Tags" should be above the footer and the grey links. Once you've scrolled to the bottom of the page and THEN refresh it re-flows correctly. I need the page to load and the two divs grow once the disqus script has loaded. Is there a way of doing this. Say getting data-equalizer to run again?

I've added the code to initiate reflow, but it hasn't helped.

Both sites need to check for additional JavaScript once the page has loaded or a Foundation JS script has run, such as changing the tabs or setting the height of a data-equalizered div.

Any ideas please?
G

(document).foundation('reflow')       

Wds grabs 2015 01 08 at 10.24.40
Rafi Benkual over 4 years ago

You can target reflow for just equalizer
$(document).foundation('equalizer', 'reflow');

You can trigger a callback after the height changes like this.

 $(document).foundation({
  equalizer: {
    after_height_change: function(){
      // do something after the height changes
    }
  }
});

James Stone over 4 years ago

Why not just load disqus async once you have scrolled to the bottom, opened the tap, etc. It already has a nice spinner would look nice loading on its own.

Glynn Williams over 4 years ago

Hi Both

I got around it by running the equalizer after a delay, so that disqus had a chance to load. There are no tabs to open James. The other website uses tabs (that I linked to the forum post). This is simply a page that uses the equalizer script and not reflow[ing] after the disqus forum loaded.

Rafi, you mention this is another post, so it did work. Cheers.