liabru / jquery-match-height

a responsive equal heights plugin
MIT License
3.07k stars 800 forks source link

only firing on some elements, not all - but all on resize #172

Open nandoblanco opened 6 years ago

nandoblanco commented 6 years ago

I have about 45 instances of the sameheight class but some are ignored, most of the time. Sometimes everything works as it should but most times the first 23 run, the next 10 don't and then the other 12 do... It works fine if I resize the window.

I tried to recreate the issue as best as possible on the jsfiddles below.

The 10 instances that don't run can be found in tab 2: People With Images and People With Images (3)

It's not waiting for the image to load since the image is set as a bg.

The really weird thing, when I minify the html it seems to work fine...

https://jsfiddle.net/nando99/hgszusvh/ - non minified html

https://jsfiddle.net/nando99/fsmj2php/ - minified html

I've been pulling my hair with this for a couple days, anyone have any ideas?

thanks in advance!

liabru commented 6 years ago

Is this still an issue? Not sure I can see the problem. My first guess would be that your html is broken (e.g. missing tags) and the minifier somehow fixes it for you?

nandoblanco commented 6 years ago

yes, still an issue :(

really dont think its the minifier but will double check

nandoblanco commented 6 years ago

and it the minifier was fixing the html, why would it work on resize... def not the minifier but again, I'll double check

nandoblanco commented 6 years ago

checked on the w3 validator, no issues...