Created
January 21, 2012 17:43
-
-
Save jarek-foksa/1653401 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Storage.prototype.set = (item, value) -> | |
@setItem item, JSON.stringify value | |
Storage.prototype.get = (item) -> | |
return JSON.parse @getItem(item) | |
Object.makeNonEnumerable Storage.prototype, ['set', 'get'] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment