Skip to content

Instantly share code, notes, and snippets.

@ahaywood
Created March 23, 2017 15:45
Show Gist options
  • Save ahaywood/cfcbb3482f3c67fb440ae82a4d11b160 to your computer and use it in GitHub Desktop.
Save ahaywood/cfcbb3482f3c67fb440ae82a4d11b160 to your computer and use it in GitHub Desktop.
Sass @each loop
$list: “Amy”, “Henry”, “Isaac”, “Adele”;
@each $person in $list {
.avatar—#{$person} {
background: url(‘avatars/#{$person}.jpg”) no-repeat;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment