Skip to content

Instantly share code, notes, and snippets.

@eprev
eprev / QLMarkdown.md
Last active January 25, 2021 22:08
GitHub Markdown style for QLMarkdown

GitHub Markdown style for QLMarkdown

Based on GitHub Markdown CSS.

Installation:

  1. Got to /Library/Quick Look or ~/Library/Quick Look and find QLMarkdown.qlgenerator.
  2. Open contextual menu for it and choose Show Package Contents.
  3. Go to Contents/Resources and find styles.css.
  4. Open it and replace its contents with the contents of this Gist.
@peeblesjs
peeblesjs / gist:9288f79322ed3119ece4
Last active February 11, 2016 23:31
A naive "valueForKey:" operator in Swift
operator infix --> {}
func --> (instance: Any, key: String) -> Any? {
let mirror = reflect(instance)
for index in 0 ..< mirror.count {
let (childKey, childMirror) = mirror[index]
if childKey == key {
return childMirror.value
}
}