Skip to content

Commit

Permalink
fixed error in Readme
Browse files Browse the repository at this point in the history
  • Loading branch information
juan-grau-wk committed May 1, 2017
1 parent 214d6ae commit 074ce9e
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions README.MD
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Promif

Promif controls your workflow control using promises (even for the test expression)
Promif controls your workflow control using promises (even for the test expression).

## promif.when

Expand All @@ -13,7 +13,7 @@ Async test function:
return new Promise(resolve=>{setTimeout(()=>resolve(true),500)});
};
promif({
promif.when({
test: asyncTestFunction
whenTrue: ()=>Promise.resolve(true);
whenFalse: ()=>Promise.resolve(false);
Expand All @@ -25,8 +25,8 @@ Sync test

let x = 23;

promif({
test: a === 23
promif.when({
test: a === 23 // Sync test (expression)
whenTrue: ()=>Promise.resolve('Yahoo');
whenFalse: ()=>Promise.resolve(false);
}).then((res)=>{
Expand Down Expand Up @@ -72,7 +72,6 @@ Every promise gets the result of the previous resolved promise
});


by jbgraug



Expand Down

0 comments on commit 074ce9e

Please sign in to comment.