Skip to content

Instantly share code, notes, and snippets.

@JulienSansot
Last active October 10, 2016 16:42
Show Gist options
  • Save JulienSansot/96fd959bc9f89f860a83b3fc082db30d to your computer and use it in GitHub Desktop.
Save JulienSansot/96fd959bc9f89f860a83b3fc082db30d to your computer and use it in GitHub Desktop.
paperclip crop
# Original image is 2048 × 2048
{
# final image is scaled down to 500x100. the cropped section is the vertical center
style_1: "500x100#",
# final image is scaled down to 100x100. It shows everything
style_2: "500x100>",
# final image is scaled down to 100x100. It shows everything. same as style_2
style_3: "500x100"
}
# Original image is 700 × 1000
{
# final image is scaled down to 175x250. It shows everything
style_4: "250x250>",
# final image is scaled down to 250x250. It is cropped
style_5: "250x250#"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment