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

devicePixelRatio rounding #274

Closed
jaykay-design opened this issue Feb 16, 2017 · 0 comments
Closed

devicePixelRatio rounding #274

jaykay-design opened this issue Feb 16, 2017 · 0 comments

Comments

@jaykay-design
Copy link

I got some strange device pixel ratios like 2.0000000298023224

I fixed it with changing line 24 to:

var environment = hasWindow ? Math.round(window.devicePixelRatio * 10) / 10 || 1 : 1;

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

No branches or pull requests

1 participant