diff --git a/README.md b/README.md index c6a532e8..fd6e26ff 100644 --- a/README.md +++ b/README.md @@ -33,7 +33,7 @@ var gun = Gun({ }); ``` -These are the default persistence layers, they are modular and can be replaced others. +These are the default persistence layers, they are modular and can be replaced by others. Using S3 is recommended for deployment, and using a file is recommended for local development. @@ -58,7 +58,7 @@ Version 0.2.0 is currently in alpha. Important changes include `.get` to `.val` GUN is not stable, and therefore should not be trusted in a production environment. *** -## API +## [API](https://github.com/amark/gun/wiki/JS-API) Below is a really basic overview of how the gun API works. For a more detailed explanation with many more examples, [check out the wiki](https://github.com/amark/gun/wiki). diff --git a/examples/package.json b/examples/package.json index 98c46f2a..f3997fdd 100644 --- a/examples/package.json +++ b/examples/package.json @@ -8,7 +8,7 @@ } , "dependencies": { "express": "~>4.9.0", - "gun": "~>0.2.0-alpha-2" + "gun": "~>0.2.0-alpha-4" } , "scripts": { "start": "node http.js", diff --git a/package.json b/package.json index 87d809df..bd194ce8 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "gun", - "version": "0.2.0-alpha-3", + "version": "0.2.0-alpha-4", "description": "Graph engine", "main": "index.js", "scripts": { diff --git a/test/common.js b/test/common.js index e004705f..5521fae4 100644 --- a/test/common.js +++ b/test/common.js @@ -1837,6 +1837,28 @@ describe('Gun', function(){ }) }); + it("ToDo", function(done){ // Simulate ToDo app! + var gun = Gun().get('example/todo/data'); + gun.on(function renderToDo(val){ + if(done.done){ return } + if(done.clear){ + done.done = true; + expect(val[done.id]).to.not.be.ok(); + return done(); + } + delete val._; + Gun.obj.map(val, function(val, field){ return done.id = field; }); + expect(val[done.id]).to.be('groceries'); + }); + setTimeout(function(){ // form submit + gun.set("groceries"); + setTimeout(function(){ // clear off element + done.clear = true; + gun.path(done.id).put(null); + },100); + },200); + }); + it("gun put null path on put sub object", function(done){ // consensus4's bug done.c = 1; var gun = Gun(); diff --git a/web/think.html b/web/think.html index 5fdaf5bd..27f7cf6c 100644 --- a/web/think.html +++ b/web/think.html @@ -73,7 +73,7 @@ var code = $('.edit').load('./editor.html', function(){setTimeout(function(){
Insert the following between the ending ul tag and the ending body tag, replacing the comment line:
@@ -97,7 +97,7 @@ var code = $('.edit').load('./editor.html', function(){setTimeout(function(){