Name: patch-drafts
Owner: Secure Scuttlebutt Consortium
Description: null
Created: 2018-03-25 21:24:56.0
Updated: 2018-03-25 21:25:28.0
Pushed: 2018-03-25 21:25:26.0
Homepage: null
Size: 39
Language: JavaScript
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
A module for storing and retreiving drafts of messages in patch-* family apps. Drafts are persisted to localStorage.
You'll need to understand depject (a module for a different way of managing dependency injection), and for hte example below, depnest - a lazy way to write nested objects quickly.
drafts.sync.get
(key) - fetch the draft stored under key
drafts.sync.set
(key, text) - set/ save some draft text under key
drafts.sync.remove
(key) - delete a draft set under key
Note key
can be a String or a Object