Skip to content

Instantly share code, notes, and snippets.

@tobiasroeder
Created June 22, 2019 08:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tobiasroeder/90e3a8a8dcc0486d49f5277eb90a3305 to your computer and use it in GitHub Desktop.
Save tobiasroeder/90e3a8a8dcc0486d49f5277eb90a3305 to your computer and use it in GitHub Desktop.
CSS before/after content property with the content from an attribute.
[data-before]::before {
content: attr(data-before);
}
[data-after]::after {
content: attr(data-after);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment