Skip to content

Instantly share code, notes, and snippets.

@robert-chiniquy
Created April 3, 2013 02:04
Show Gist options
  • Save robert-chiniquy/5297869 to your computer and use it in GitHub Desktop.
Save robert-chiniquy/5297869 to your computer and use it in GitHub Desktop.
crime in chicago json
{ template: '<div class="panel {{class}}">\n <h3>{{header}}</h3>\n\n <ol class="chart-bar">\n {{#categories}}\n <li>\n <span class="point">\n <span class="idx" style="width: {{width}}%;"></span>\n <span class="label">{{category_name}}</span>\n <span class="count">{{crime_count}}</span>\n </span>\n </li>\n {{/categories}}\n </ol>\n</div>\n',
class: 'category',
header: 'Most frequent',
categories:
[ { crime_count: 1760,
category_name: 'Simple Battery',
width: 100 },
{ crime_count: 1329,
category_name: 'Theft',
width: 76 },
{ crime_count: 1077,
category_name: 'Vandalism',
width: 61 },
{ crime_count: 906,
category_name: 'Burglary',
width: 51 },
{ crime_count: 846,
category_name: 'Drug Abuse',
width: 48 },
{ crime_count: 735,
category_name: 'Miscellaneous',
width: 42 } ] }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment