MCPcopy Index your code
hub / github.com/stemdeckapp/stemdeck / update

Function update

desktop/ui/setup.js:70–80  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

68 let messageIndex = 0;
69
70 const update = () => {
71 const elapsedSeconds = Math.floor((Date.now() - startedAt) / 1000);
72 while (
73 messageIndex + 1 < messages.length &&
74 elapsedSeconds >= messages[messageIndex + 1].afterSeconds
75 ) {
76 messageIndex += 1;
77 }
78
79 setStatus(`${messages[messageIndex].text} Elapsed: ${formatElapsed(startedAt)}.`);
80 };
81
82 update();
83 const timer = window.setInterval(update, 1000);

Callers 1

startProgressStatusFunction · 0.85

Calls 2

setStatusFunction · 0.85
formatElapsedFunction · 0.85

Tested by

no test coverage detected