sprinkles icon indicating copy to clipboard operation
sprinkles copied to clipboard

A little sugar for your vanilla JS 🍦

Results 20 sprinkles issues
Sort by recently updated
recently updated
newest added

I've cooked up two animation helpers over the years: `animate()` and `queueAnimation()`. Doing hardware-accelerated animations purely by adding/removing classes is just impossible. So I want to polish up these functions...

Extracted from #13.

enhancement

Extracted from #13.

enhancement

``` js pushItem(k, v) { var a = getItems(k); a.push(v); localStorage.setItem(JSON.stringify(a)); } ``` ``` js getItems(k) { var a = getObject(k); if (a == null) a = []; return a;...

enhancement

Just like how [Rails](http://api.rubyonrails.org/classes/ActionView/Helpers/NumberHelper.html#method-i-number_with_delimiter) does. This will (eventually) have to leverage whatever I18n solution gets sorted out. Can get a lot of inspiration from Rails for sure.

Certain methods like `Date.prototype.dayName()` assume English.

enhancement

``` js "The quick brown fox jumped over the lazy dog".truncate(10) // => "The qui..." "The quick brown fox jumped over the lazy dog".truncateFromCenter(10) // => "The ...dog" ```

enhancement

Allow objects to be serialized so that this: ``` js { foo: "bar", baz: "qux" } ``` Becomes this: ``` js "foo=bar&baz=qux" ``` Like [`jQuery.param()`](http://api.jquery.com/jQuery.param/).

enhancement