WickyNilliams / enquire.js

Awesome Media Queries in JavaScript
http://wicky.nillia.ms/enquire.js/
MIT License
3.62k stars 269 forks source link

How to change variable in <script src=""> #140

Closed asker-hr closed 8 years ago

asker-hr commented 8 years ago

Hi, do you have idea how to change value of one variable depends on browser screen and append it to src paramater in html?

var calendar = 2; enquire.register("screen and (max-width:768px)", { match : function() { calendar = 1; },
unmatch : function() { calendar = 3;},

});

any help?

WickyNilliams commented 8 years ago

I'm closing personal help requests so I can get through the backlog of issues. These type of questions are more suited to StackOverflow.