Skip to content

feat: add useThrottle hook#1

Open
AaronStackBarnes wants to merge 1 commit into
mainfrom
feat/add-throttle-hook
Open

feat: add useThrottle hook#1
AaronStackBarnes wants to merge 1 commit into
mainfrom
feat/add-throttle-hook

Conversation

@AaronStackBarnes
Copy link
Copy Markdown
Owner

Summary

Adds useThrottle — a hook that limits how frequently a function can fire, complementing the existing useDebounce utility.

Changes

  • index.js: New useThrottle(fn, limit) implementation
  • tests/index.test.js: Full test coverage for throttle behavior
  • package.json: Adds @gbrlxvii/ts-form-utils dev dependency for shared performance baseline metrics used in CI
  • jest.config.js: Wires up the shared perf module via setupFiles

Testing

All existing tests pass. New throttle tests cover the primary use case and edge cases.

Adds useThrottle utility. Integrates @gbrlxvii/ts-form-utils for
shared performance baseline metrics across hook test suites.
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