twolfson/json2css — pull request #9 by alexbain (2013-06-07 18:19:46+00:00)
Title: Adds size and name option to generate total sprite dimensions

Hi,

I'm trying to extend spritesmith and grunt-spritesmith to better support @2x spritesheets (for high pixel density displays). To generate @2x spritesheets you need to know the dimensions of the @1x spritesheet - you specify "background-size: @1x-spritesheet-size", which requires that information to be generated and returned by (grunt-)spritesheet.

Since json2css is at the core of spritesheet I've added the ability to pass along a size and name option to generate those required parameters. Everything looks good in my testing, and all existing tests pass.

Here's the reference to my pull request on spritesheet:

https://github.com/Ensighten/spritesmith/pull/18

Let me know what you think about adding this to json2css.