jQuery : how to refresh on window resize

Hi! I’m dynamically giving a couple of div’s a certain height through jquery:

$(‘.column’).height(function(index, height) {
return window.innerHeight - $(this).offset().top;
});

How can I get this code to automatically recalculate the height values when the browser window is resized? thank you so much :wink:

work on this https://alvarotrigo.com/blog/firing-resize-event-only-once-when-resizing-is-finished/

1 Like