node package manager
Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org »

responsive-resize

responsive-resize

Helper to manage media queries in javascript.

Usage:

  ResponsiveResize.register("(max-width: 1000px)", function(){
    console.log('entering 1000');
    document.body.style.backgroundColor = 'blue'
  }, function(){
    console.log('exiting 1000');
    document.body.style.backgroundColor = 'purple'
  });