Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var resizeTicking = false;
- window.addEventListener('resize', function () {
- if (!resizeTicking) {
- window.requestAnimationFrame(function () {
- // ...
- resizeTicking = false;
- });
- }
- resizeTicking = true;
- });
Add Comment
Please, Sign In to add comment