Skip to content

Use useTick instead of setInterval in devtools demo#11

Merged
hardy30894 merged 1 commit intoorchetron:mainfrom
Chhavi001:feat/use-tick-devtools-demo
Apr 15, 2026
Merged

Use useTick instead of setInterval in devtools demo#11
hardy30894 merged 1 commit intoorchetron:mainfrom
Chhavi001:feat/use-tick-devtools-demo

Conversation

@Chhavi001
Copy link
Copy Markdown
Contributor

What changed

  • Replaced setInterval with useTick in the devtools demo clock and counter.
  • Did some small JSX formatting tweaks.

Why

  • useTick is the recommended timer API in this library.
  • Cleans up manual interval setup and cleanup.

Checklist

  • npx tsc --noEmit passes
  • npx vitest run passes
  • New exports added to src/index.ts
  • Documentation updated in docs/
    Note: 'npx vitest run' fails locally only on performance benchmark tests in src/tests/benchmarks.test.ts (time thresholds). Functional tests are passing.

@Chhavi001
Copy link
Copy Markdown
Contributor Author

Hi! 👋

This PR replaces setInterval with useTick in the devtools demo clock and counter, to align with the recommended timer API. Please let me know if any changes are needed.

Thanks!

@hardy30894
Copy link
Copy Markdown
Member

nit: trailing line in the end.

@Chhavi001
Copy link
Copy Markdown
Contributor Author

Thanks for the review! I checked the file and it ends at line 159 with await app.waitUntilExit(); — there's no trailing line after that. Could you please point me to the exact location? Happy to fix it!

@hardy30894 hardy30894 merged commit dbb6a46 into orchetron:main Apr 15, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants