From a93e2a7c31cdbaa621ea8c0678c2b7997a72f075 Mon Sep 17 00:00:00 2001 From: Leon Date: Wed, 7 Dec 2016 20:07:55 +0100 Subject: [PATCH 1/2] updated docs with async example --- README.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/README.md b/README.md index e18f688..9d442bc 100644 --- a/README.md +++ b/README.md @@ -84,3 +84,16 @@ The body of the request. // Return the sum of the a and b properties {a: 5, b: 1} setResult(body.a + body.b); + +## Async requests + +By default the event-code will automatically be finished by a response. +Here's how to do async requests: + + + var done = ctx.done // remember this to end the response (async) + ctx.done = function(){} // dummy function for autoresponse (sync) + + ctx.dpd.myresource.get({id: id}, function(result) { + done(result) + }); From 70de48bbb0b8c08bbfe4c0168d25406d3a91119d Mon Sep 17 00:00:00 2001 From: Leon Date: Thu, 28 May 2020 20:48:55 +0200 Subject: [PATCH 2/2] added sponsor-button --- .github/FUNDING.yml | 1 + 1 file changed, 1 insertion(+) create mode 100644 .github/FUNDING.yml diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 0000000..f744573 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1 @@ +custom: https://gumroad.com/l/hGYGh