Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/redux-loop/redux-loop
/ delay
Function
delay
example/src/delay.js:1–9 ·
view source on GitHub ↗
(milliseconds)
Source
from the content-addressed store, hash-verified
1
export
default
function
delay (milliseconds) {
2
return
new
Promise((resolve, reject) => {
3
const
shouldFail = Math.random() <= 0.2;
4
setTimeout(() => {
5
if
(shouldFail) reject();
6
else
resolve();
7
}, milliseconds);
8
});
9
}
Callers
1
index.js
File · 0.70
Calls
no outgoing calls
Tested by
no test coverage detected