Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using Joyride when you are already using Modernizr.mq #152

Open
itsmattsoria opened this issue Nov 7, 2013 · 0 comments
Open

Using Joyride when you are already using Modernizr.mq #152

itsmattsoria opened this issue Nov 7, 2013 · 0 comments

Comments

@itsmattsoria
Copy link

The app I'm using Joyride with already has a custom build of Modernizr that includes the media query check, so for the sake of not being redundant I don't want to include the modernizr.mq.js file included with Joyride. After some testing I found that the Modernizr.mq wasn't being used though, rather the fall-back jquery $window.width() (line 360 of jquery.joyride-2.1.js), which is inconsistent.
Getting rid of Modernizr = Modernizr || false, on line 54 of jquery.joyride-2.1.js fixes the issue though, and it is my understanding that in theory it should still work if using the included modernizr.mq.js file.
Can this line be removed? Has anyone else had the same issue? I submitted a pull request to add an option in the settings to set your own breakpoint rather than the default 768px as well (#151), but that also is sort of redundant if you are using your own build of Modernizr.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants