Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Generated by SassMeister.com.
// ----
// Sass (v3.4.13)
// Compass (v1.0.3)
// ----
$images-base-path: 'test/';
@mixin retinaBg($path) {
background-image: url($images-base-path + $path +'.png');
@media only screen and (min-device-pixel-ratio: 2),
only screen and (min-resolution: 192dpi) {
background-image: url($images-base-path + $path +'@2x.png');
}
}
.foo{
@include retinaBg('/icons/options/sms');
}
.foo {
background-image: url(test//icons/options/sms.png?1431340934);
}
@media only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi) {
.foo {
background-image: url(test//icons/options/sms@2x.png?1431340934);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.