├── .changeset └── config.json ├── .cursor ├── mcp.json └── rules │ └── jsdoc.mdc ├── .editorconfig ├── .gitattributes ├── .github ├── FUNDING.yml ├── ISSUE_TEMPLATE │ ├── bug_report.yml │ └── config.yml ├── renovate.json └── workflows │ ├── autofix.yml │ ├── pr.yml │ └── release.yml ├── .gitignore ├── .npmrc ├── .nvmrc ├── .nx └── workflows │ └── dynamic-changesets.yaml ├── .prettierignore ├── .vscode └── extensions.json ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── docs ├── config.json ├── framework │ ├── react │ │ ├── adapter.md │ │ └── reference │ │ │ ├── functions │ │ │ ├── useasyncdebouncer.md │ │ │ ├── useasyncqueuedstate.md │ │ │ ├── useasyncqueuer.md │ │ │ ├── useasyncratelimiter.md │ │ │ ├── useasyncthrottler.md │ │ │ ├── usebatcher.md │ │ │ ├── usedebouncedcallback.md │ │ │ ├── usedebouncedstate.md │ │ │ ├── usedebouncedvalue.md │ │ │ ├── usedebouncer.md │ │ │ ├── usequeuedstate.md │ │ │ ├── usequeuedvalue.md │ │ │ ├── usequeuer.md │ │ │ ├── useratelimitedcallback.md │ │ │ ├── useratelimitedstate.md │ │ │ ├── useratelimitedvalue.md │ │ │ ├── useratelimiter.md │ │ │ ├── usethrottledcallback.md │ │ │ ├── usethrottledstate.md │ │ │ ├── usethrottledvalue.md │ │ │ └── usethrottler.md │ │ │ └── index.md │ └── solid │ │ ├── adapter.md │ │ └── reference │ │ ├── functions │ │ ├── createasyncdebouncer.md │ │ ├── createasyncqueuer.md │ │ ├── createasyncratelimiter.md │ │ ├── createasyncthrottler.md │ │ ├── createbatcher.md │ │ ├── createdebouncedsignal.md │ │ ├── createdebouncedvalue.md │ │ ├── createdebouncer.md │ │ ├── createqueuer.md │ │ ├── createratelimitedsignal.md │ │ ├── createratelimitedvalue.md │ │ ├── createratelimiter.md │ │ ├── createthrottledsignal.md │ │ ├── createthrottledvalue.md │ │ └── createthrottler.md │ │ ├── index.md │ │ └── interfaces │ │ ├── solidasyncdebouncer.md │ │ ├── solidasyncqueuer.md │ │ ├── solidasyncratelimiter.md │ │ ├── solidasyncthrottler.md │ │ ├── solidbatcher.md │ │ ├── soliddebouncer.md │ │ ├── solidqueuer.md │ │ ├── solidratelimiter.md │ │ └── solidthrottler.md ├── guides │ ├── async-debouncing.md │ ├── async-queuing.md │ ├── async-rate-limiting.md │ ├── async-throttling.md │ ├── batching.md │ ├── debouncing.md │ ├── queuing.md │ ├── rate-limiting.md │ ├── server-rate-limiting.md │ └── throttling.md ├── installation.md ├── overview.md ├── quick-start.md └── reference │ ├── classes │ ├── asyncdebouncer.md │ ├── asyncqueuer.md │ ├── asyncratelimiter.md │ ├── asyncthrottler.md │ ├── batcher.md │ ├── debouncer.md │ ├── queuer.md │ ├── ratelimiter.md │ └── throttler.md │ ├── functions │ ├── asyncdebounce.md │ ├── asyncqueue.md │ ├── asyncratelimit.md │ ├── asyncthrottle.md │ ├── batch.md │ ├── bindinstancemethods.md │ ├── debounce.md │ ├── isfunction.md │ ├── isplainarray.md │ ├── isplainobject.md │ ├── parsefunctionorvalue.md │ ├── queue.md │ ├── ratelimit.md │ ├── replaceequaldeep.md │ ├── shallowequalobjects.md │ └── throttle.md │ ├── index.md │ ├── interfaces │ ├── asyncdebounceroptions.md │ ├── asyncqueueroptions.md │ ├── asyncratelimiteroptions.md │ ├── asyncthrottleroptions.md │ ├── batcheroptions.md │ ├── debounceroptions.md │ ├── queueroptions.md │ ├── ratelimiteroptions.md │ └── throttleroptions.md │ └── type-aliases │ ├── anyasyncfunction.md │ ├── anyfunction.md │ ├── optionalkeys.md │ └── queueposition.md ├── eslint.config.js ├── examples ├── react │ ├── asyncDebounce │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── asyncRateLimit │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── asyncThrottle │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── batch │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── debounce │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── queue │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── rateLimit │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── react-query-debounced-prefetch │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── react-query-queued-prefetch │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── react-query-throttled-prefetch │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── throttle │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useAsyncDebouncer │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useAsyncQueuedState │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useAsyncQueuer │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useAsyncRateLimiter │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useAsyncThrottler │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useBatcher │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useDebouncedCallback │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useDebouncedState │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useDebouncedValue │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useDebouncer │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useQueuedState │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useQueuedValue │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useQueuer │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useRateLimitedCallback │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useRateLimitedState │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useRateLimitedValue │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useRateLimiter │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useThrottledCallback │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useThrottledState │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ ├── useThrottledValue │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ │ └── emblem-light.svg │ │ ├── src │ │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts │ └── useThrottler │ │ ├── .eslintrc.cjs │ │ ├── .gitignore │ │ ├── README.md │ │ ├── index.html │ │ ├── package.json │ │ ├── public │ │ └── emblem-light.svg │ │ ├── src │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── vite.config.ts └── solid │ ├── asyncDebounce │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── asyncRateLimit │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── asyncThrottle │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── batch │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createAsyncDebouncer │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createAsyncQueuer │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createAsyncRateLimiter │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createAsyncThrottler │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createBatcher │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createDebouncedSignal │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createDebouncedValue │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createDebouncer │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createQueuer │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createRateLimitedSignal │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createRateLimitedValue │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createRateLimiter │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createThrottledSignal │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createThrottledValue │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── createThrottler │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── debounce │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── queue │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ ├── rateLimit │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ │ └── emblem-light.svg │ ├── src │ │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts │ └── throttle │ ├── .eslintrc.cjs │ ├── .gitignore │ ├── README.md │ ├── index.html │ ├── package.json │ ├── public │ └── emblem-light.svg │ ├── src │ └── index.tsx │ ├── tsconfig.json │ └── vite.config.ts ├── knip.json ├── nx.json ├── package.json ├── packages ├── pacer │ ├── CHANGELOG.md │ ├── eslint.config.js │ ├── package.json │ ├── src │ │ ├── async-debouncer.ts │ │ ├── async-queuer.ts │ │ ├── async-rate-limiter.ts │ │ ├── async-throttler.ts │ │ ├── batcher.ts │ │ ├── compare.ts │ │ ├── debouncer.ts │ │ ├── index.ts │ │ ├── queuer.ts │ │ ├── rate-limiter.ts │ │ ├── throttler.ts │ │ ├── types.ts │ │ └── utils.ts │ ├── tests │ │ ├── async-debouncer.test.ts │ │ ├── async-queuer.test.ts │ │ ├── async-rate-limiter.test.ts │ │ ├── async-throttler.test.ts │ │ ├── compare.test.ts │ │ ├── debouncer.test.ts │ │ ├── queuer.test.ts │ │ ├── rate-limiter.test.ts │ │ ├── test-setup.ts │ │ ├── throttler.test.ts │ │ └── utils.test.ts │ ├── tsconfig.docs.json │ ├── tsconfig.json │ └── vite.config.ts ├── react-pacer │ ├── CHANGELOG.md │ ├── eslint.config.js │ ├── package.json │ ├── src │ │ ├── async-debouncer │ │ │ ├── index.ts │ │ │ └── useAsyncDebouncer.ts │ │ ├── async-queuer │ │ │ ├── index.ts │ │ │ ├── useAsyncQueuedState.ts │ │ │ └── useAsyncQueuer.ts │ │ ├── async-rate-limiter │ │ │ ├── index.ts │ │ │ └── useAsyncRateLimiter.ts │ │ ├── async-throttler │ │ │ ├── index.ts │ │ │ └── useAsyncThrottler.ts │ │ ├── batcher │ │ │ ├── index.ts │ │ │ └── useBatcher.ts │ │ ├── compare │ │ │ └── index.ts │ │ ├── debouncer │ │ │ ├── index.ts │ │ │ ├── useDebouncedCallback.ts │ │ │ ├── useDebouncedState.ts │ │ │ ├── useDebouncedValue.ts │ │ │ └── useDebouncer.ts │ │ ├── index.ts │ │ ├── queuer │ │ │ ├── index.ts │ │ │ ├── useQueuedState.ts │ │ │ ├── useQueuedValue.ts │ │ │ └── useQueuer.ts │ │ ├── rate-limiter │ │ │ ├── index.ts │ │ │ ├── useRateLimitedCallback.ts │ │ │ ├── useRateLimitedState.ts │ │ │ ├── useRateLimitedValue.ts │ │ │ └── useRateLimiter.ts │ │ ├── throttler │ │ │ ├── index.ts │ │ │ ├── useThrottledCallback.ts │ │ │ ├── useThrottledState.ts │ │ │ ├── useThrottledValue.ts │ │ │ └── useThrottler.ts │ │ ├── types │ │ │ └── index.ts │ │ └── utils │ │ │ └── index.ts │ ├── tsconfig.docs.json │ ├── tsconfig.json │ └── vite.config.ts └── solid-pacer │ ├── CHANGELOG.md │ ├── eslint.config.js │ ├── package.json │ ├── src │ ├── async-debouncer │ │ ├── createAsyncDebouncer.ts │ │ └── index.ts │ ├── async-queuer │ │ ├── createAsyncQueuer.ts │ │ └── index.ts │ ├── async-rate-limiter │ │ ├── createAsyncRateLimiter.ts │ │ └── index.ts │ ├── async-throttler │ │ ├── createAsyncThrottler.ts │ │ └── index.ts │ ├── batcher │ │ ├── createBatcher.ts │ │ └── index.ts │ ├── compare │ │ └── index.ts │ ├── debouncer │ │ ├── createDebouncedSignal.ts │ │ ├── createDebouncedValue.ts │ │ ├── createDebouncer.ts │ │ └── index.ts │ ├── index.ts │ ├── queuer │ │ ├── createQueuer.ts │ │ └── index.ts │ ├── rate-limiter │ │ ├── createRateLimitedSignal.ts │ │ ├── createRateLimitedValue.ts │ │ ├── createRateLimiter.ts │ │ └── index.ts │ ├── throttler │ │ ├── createThrottledSignal.ts │ │ ├── createThrottledValue.ts │ │ ├── createThrottler.ts │ │ └── index.ts │ ├── types │ │ └── index.ts │ └── utils │ │ └── index.ts │ ├── tsconfig.docs.json │ ├── tsconfig.json │ └── vite.config.ts ├── pnpm-lock.yaml ├── pnpm-workspace.yaml ├── prettier.config.js ├── scripts ├── generateDocs.js └── verify-links.ts ├── tsconfig.json └── vitest.workspace.js /.changeset/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://unpkg.com/@changesets/config@3.1.1/schema.json", 3 | "changelog": [ 4 | "@svitejs/changesets-changelog-github-compact", 5 | { "repo": "TanStack/pacer" } 6 | ], 7 | "commit": false, 8 | "access": "public", 9 | "baseBranch": "main", 10 | "updateInternalDependencies": "patch", 11 | "fixed": [], 12 | "linked": [], 13 | "ignore": [] 14 | } 15 | -------------------------------------------------------------------------------- /.cursor/mcp.json: -------------------------------------------------------------------------------- 1 | { 2 | "mcpServers": { 3 | "nx-mcp": { 4 | "url": "http://localhost:9160/sse" 5 | } 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /.cursor/rules/jsdoc.mdc: -------------------------------------------------------------------------------- 1 | --- 2 | description: 3 | globs: 4 | alwaysApply: true 5 | --- 6 | # Your rule content 7 | 8 | - The JSDoc in this repo is important as it gets converted to markdown docs for the website, so it should read like documentation. 9 | - Don't include `@params`, `@args`, `@template`, or `@returns` in our jsdoc 10 | -------------------------------------------------------------------------------- /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | charset = utf-8 5 | indent_style = space 6 | indent_size = 2 7 | end_of_line = lf 8 | insert_final_newline = true 9 | trim_trailing_whitespace = true 10 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | # These are supported funding model platforms 2 | 3 | github: tannerlinsley 4 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/config.yml: -------------------------------------------------------------------------------- 1 | blank_issues_enabled: false 2 | contact_links: 3 | - name: Feature Requests & Questions 4 | url: https://github.com/TanStack/table/discussions 5 | about: Please ask and answer questions here. 6 | - name: Community Chat 7 | url: https://discord.gg/mQd7egN 8 | about: A dedicated discord server hosted by TanStack 9 | -------------------------------------------------------------------------------- /.github/renovate.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://docs.renovatebot.com/renovate-schema.json", 3 | "configMigration": true, 4 | "extends": [ 5 | "config:recommended", 6 | "group:allNonMajor", 7 | "schedule:weekly", 8 | ":approveMajorUpdates", 9 | ":automergeMinor", 10 | ":disablePeerDependencies", 11 | ":maintainLockFilesMonthly", 12 | ":semanticCommits", 13 | ":semanticCommitTypeAll(chore)" 14 | ], 15 | "ignorePresets": [":ignoreModulesAndTests"], 16 | "labels": ["dependencies"], 17 | "rangeStrategy": "bump", 18 | "postUpdateOptions": ["pnpmDedupe"], 19 | "ignoreDeps": ["@types/node", "node"] 20 | } 21 | -------------------------------------------------------------------------------- /.npmrc: -------------------------------------------------------------------------------- 1 | link-workspace-packages=true 2 | prefer-workspace-packages=true 3 | provenance=true 4 | -------------------------------------------------------------------------------- /.nvmrc: -------------------------------------------------------------------------------- 1 | 22.12.0 2 | -------------------------------------------------------------------------------- /.nx/workflows/dynamic-changesets.yaml: -------------------------------------------------------------------------------- 1 | distribute-on: 2 | small-changeset: 3 linux-medium-js 3 | medium-changeset: 6 linux-medium-js 4 | large-changeset: 10 linux-medium-js 5 | -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | **/.nx/ 2 | **/.nx/cache 3 | **/.svelte-kit 4 | **/build 5 | **/coverage 6 | **/dist 7 | **/docs 8 | **/old-examples 9 | pnpm-lock.yaml 10 | 11 | .angular 12 | -------------------------------------------------------------------------------- /.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | "recommendations": [ 3 | "vitest.explorer", 4 | "dbaeumer.vscode-eslint", 5 | "esbenp.prettier-vscode" 6 | ] 7 | } 8 | -------------------------------------------------------------------------------- /docs/framework/solid/adapter.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: TanStack Pacer Solid Adapter 3 | ref: docs/framework/react/adapter.md 4 | replace: { 5 | "React": "Solid", 6 | "react": "solid" 7 | } 8 | --- 9 | -------------------------------------------------------------------------------- /docs/guides/server-rate-limiting.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Server Rate Limiting Guide 3 | id: server-rate-limiting 4 | --- 5 | 6 | -------------------------------------------------------------------------------- /docs/installation.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Installation 3 | id: installation 4 | --- 5 | 6 | You can install TanStack Pacer with any [NPM](https://npmjs.com) package manager. 7 | 8 | Only install one of the following packages depending on your use case: 9 | 10 | ## React 11 | 12 | ```sh 13 | npm install @tanstack/react-pacer 14 | ``` 15 | 16 | TanStack Pacer is compatible with React v16.8+ 17 | 18 | ## Solid 19 | 20 | ```sh 21 | npm install @tanstack/solid-pacer 22 | ``` 23 | 24 | TanStack Pacer is compatible with Solid v1.9.5+ 25 | 26 | ## Vanilla JS 27 | 28 | ```sh 29 | npm install @tanstack/pacer 30 | ``` 31 | 32 | Install the the core `@tanstack/pacer` package to use with any framework or without a framework. Each framework package up above will also re-export everything from this core package. 33 | -------------------------------------------------------------------------------- /docs/quick-start.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: Quick Start 3 | id: quick-start 4 | --- 5 | 6 | TanStack Pacer is, first and foremost, a framework-agnostic utility library for rate limiting, throttling, debouncing, and queuing. 7 | 8 | It can be used with any of our framework adapters, but can also be used in vanilla JavaScript or TypeScript. -------------------------------------------------------------------------------- /docs/reference/functions/bindinstancemethods.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: bindInstanceMethods 3 | title: bindInstanceMethods 4 | --- 5 | 6 | 7 | 8 | # Function: bindInstanceMethods() 9 | 10 | ```ts 11 | function bindInstanceMethods(instance): T 12 | ``` 13 | 14 | Defined in: [utils.ts:14](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/utils.ts#L14) 15 | 16 | ## Type Parameters 17 | 18 | • **T** *extends* `Record`\<`string`, `any`\> 19 | 20 | ## Parameters 21 | 22 | ### instance 23 | 24 | `T` 25 | 26 | ## Returns 27 | 28 | `T` 29 | -------------------------------------------------------------------------------- /docs/reference/functions/isfunction.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: isFunction 3 | title: isFunction 4 | --- 5 | 6 | 7 | 8 | # Function: isFunction() 9 | 10 | ```ts 11 | function isFunction(value): value is T 12 | ``` 13 | 14 | Defined in: [utils.ts:3](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/utils.ts#L3) 15 | 16 | ## Type Parameters 17 | 18 | • **T** *extends* [`AnyFunction`](../../type-aliases/anyfunction.md) 19 | 20 | ## Parameters 21 | 22 | ### value 23 | 24 | `any` 25 | 26 | ## Returns 27 | 28 | `value is T` 29 | -------------------------------------------------------------------------------- /docs/reference/functions/isplainarray.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: isPlainArray 3 | title: isPlainArray 4 | --- 5 | 6 | 7 | 8 | # Function: isPlainArray() 9 | 10 | ```ts 11 | function isPlainArray(value): boolean 12 | ``` 13 | 14 | Defined in: [compare.ts:66](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/compare.ts#L66) 15 | 16 | ## Parameters 17 | 18 | ### value 19 | 20 | `unknown` 21 | 22 | ## Returns 23 | 24 | `boolean` 25 | -------------------------------------------------------------------------------- /docs/reference/functions/isplainobject.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: isPlainObject 3 | title: isPlainObject 4 | --- 5 | 6 | 7 | 8 | # Function: isPlainObject() 9 | 10 | ```ts 11 | function isPlainObject(o): o is Object 12 | ``` 13 | 14 | Defined in: [compare.ts:72](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/compare.ts#L72) 15 | 16 | ## Parameters 17 | 18 | ### o 19 | 20 | `any` 21 | 22 | ## Returns 23 | 24 | `o is Object` 25 | -------------------------------------------------------------------------------- /docs/reference/functions/parsefunctionorvalue.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: parseFunctionOrValue 3 | title: parseFunctionOrValue 4 | --- 5 | 6 | 7 | 8 | # Function: parseFunctionOrValue() 9 | 10 | ```ts 11 | function parseFunctionOrValue(value, ...args): T 12 | ``` 13 | 14 | Defined in: [utils.ts:7](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/utils.ts#L7) 15 | 16 | ## Type Parameters 17 | 18 | • **T** 19 | 20 | • **TArgs** *extends* `any`[] 21 | 22 | ## Parameters 23 | 24 | ### value 25 | 26 | `T` | (...`args`) => `T` 27 | 28 | ### args 29 | 30 | ...`TArgs` 31 | 32 | ## Returns 33 | 34 | `T` 35 | -------------------------------------------------------------------------------- /docs/reference/functions/replaceequaldeep.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: replaceEqualDeep 3 | title: replaceEqualDeep 4 | --- 5 | 6 | 7 | 8 | # Function: replaceEqualDeep() 9 | 10 | ```ts 11 | function replaceEqualDeep(a, b): T 12 | ``` 13 | 14 | Defined in: [compare.ts:6](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/compare.ts#L6) 15 | 16 | This function returns `a` if `b` is deeply equal. 17 | If not, it will replace any deeply equal children of `b` with those of `a`. 18 | This can be used for structural sharing between JSON values for example. 19 | 20 | ## Type Parameters 21 | 22 | • **T** 23 | 24 | ## Parameters 25 | 26 | ### a 27 | 28 | `unknown` 29 | 30 | ### b 31 | 32 | `T` 33 | 34 | ## Returns 35 | 36 | `T` 37 | -------------------------------------------------------------------------------- /docs/reference/functions/shallowequalobjects.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: shallowEqualObjects 3 | title: shallowEqualObjects 4 | --- 5 | 6 | 7 | 8 | # Function: shallowEqualObjects() 9 | 10 | ```ts 11 | function shallowEqualObjects(a, b): boolean 12 | ``` 13 | 14 | Defined in: [compare.ts:49](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/compare.ts#L49) 15 | 16 | Shallow compare objects. 17 | 18 | ## Type Parameters 19 | 20 | • **T** *extends* `Record`\<`string`, `any`\> 21 | 22 | ## Parameters 23 | 24 | ### a 25 | 26 | `T` 27 | 28 | ### b 29 | 30 | `undefined` | `T` 31 | 32 | ## Returns 33 | 34 | `boolean` 35 | -------------------------------------------------------------------------------- /docs/reference/type-aliases/anyasyncfunction.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: AnyAsyncFunction 3 | title: AnyAsyncFunction 4 | --- 5 | 6 | 7 | 8 | # Type Alias: AnyAsyncFunction() 9 | 10 | ```ts 11 | type AnyAsyncFunction = (...args) => Promise; 12 | ``` 13 | 14 | Defined in: [types.ts:9](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/types.ts#L9) 15 | 16 | Represents an asynchronous function that can be called with any arguments and returns a promise. 17 | 18 | ## Parameters 19 | 20 | ### args 21 | 22 | ...`any`[] 23 | 24 | ## Returns 25 | 26 | `Promise`\<`any`\> 27 | -------------------------------------------------------------------------------- /docs/reference/type-aliases/anyfunction.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: AnyFunction 3 | title: AnyFunction 4 | --- 5 | 6 | 7 | 8 | # Type Alias: AnyFunction() 9 | 10 | ```ts 11 | type AnyFunction = (...args) => any; 12 | ``` 13 | 14 | Defined in: [types.ts:4](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/types.ts#L4) 15 | 16 | Represents a function that can be called with any arguments and returns any value. 17 | 18 | ## Parameters 19 | 20 | ### args 21 | 22 | ...`any`[] 23 | 24 | ## Returns 25 | 26 | `any` 27 | -------------------------------------------------------------------------------- /docs/reference/type-aliases/optionalkeys.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: OptionalKeys 3 | title: OptionalKeys 4 | --- 5 | 6 | 7 | 8 | # Type Alias: OptionalKeys\ 9 | 10 | ```ts 11 | type OptionalKeys = Omit & Partial>; 12 | ``` 13 | 14 | Defined in: [types.ts:11](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/types.ts#L11) 15 | 16 | ## Type Parameters 17 | 18 | • **T** 19 | 20 | • **TKey** *extends* keyof `T` 21 | -------------------------------------------------------------------------------- /docs/reference/type-aliases/queueposition.md: -------------------------------------------------------------------------------- 1 | --- 2 | id: QueuePosition 3 | title: QueuePosition 4 | --- 5 | 6 | 7 | 8 | # Type Alias: QueuePosition 9 | 10 | ```ts 11 | type QueuePosition = "front" | "back"; 12 | ``` 13 | 14 | Defined in: [queuer.ts:97](https://github.com/TanStack/pacer/blob/main/packages/pacer/src/queuer.ts#L97) 15 | 16 | Position type for addItem and getNextItem operations. 17 | 18 | - 'front': Operate on the front of the queue (FIFO) 19 | - 'back': Operate on the back of the queue (LIFO) 20 | -------------------------------------------------------------------------------- /eslint.config.js: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | // @ts-ignore Needed due to moduleResolution Node vs Bundler 4 | import { tanstackConfig } from '@tanstack/config/eslint' 5 | import unusedImports from 'eslint-plugin-unused-imports' 6 | 7 | export default [ 8 | ...tanstackConfig, 9 | { 10 | name: 'tanstack/temp', 11 | plugins: { 12 | 'unused-imports': unusedImports, 13 | }, 14 | rules: { 15 | 'no-case-declarations': 'off', 16 | 'no-shadow': 'off', 17 | 'unused-imports/no-unused-imports': 'warn', 18 | }, 19 | }, 20 | ] 21 | -------------------------------------------------------------------------------- /examples/react/asyncDebounce/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/asyncDebounce/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/asyncDebounce/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/asyncDebounce/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/asyncDebounce/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/asyncDebounce/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/asyncRateLimit/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/asyncRateLimit/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/asyncRateLimit/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/asyncRateLimit/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/asyncRateLimit/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/asyncRateLimit/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/asyncThrottle/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/asyncThrottle/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/asyncThrottle/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/asyncThrottle/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/asyncThrottle/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/asyncThrottle/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/batch/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/batch/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/batch/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/batch/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/batch/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/batch/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/debounce/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/debounce/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/debounce/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/debounce/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/debounce/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/debounce/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/queue/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/queue/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/queue/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/queue/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/queue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/queue/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/rateLimit/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/rateLimit/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/rateLimit/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/rateLimit/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/rateLimit/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/rateLimit/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/react-query-debounced-prefetch/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/react-query-debounced-prefetch/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/react-query-debounced-prefetch/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/react-query-debounced-prefetch/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/react-query-debounced-prefetch/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/react-query-debounced-prefetch/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/react-query-queued-prefetch/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/react-query-queued-prefetch/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/react-query-queued-prefetch/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/react-query-queued-prefetch/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/react-query-queued-prefetch/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/react-query-queued-prefetch/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/react-query-throttled-prefetch/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/react-query-throttled-prefetch/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/react-query-throttled-prefetch/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/react-query-throttled-prefetch/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/react-query-throttled-prefetch/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/react-query-throttled-prefetch/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/throttle/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/throttle/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/throttle/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/throttle/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/throttle/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/throttle/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncDebouncer/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncDebouncer/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useAsyncDebouncer/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useAsyncDebouncer/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useAsyncDebouncer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useAsyncDebouncer/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuedState/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuedState/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuedState/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuedState/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuedState/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuedState/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuer/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuer/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuer/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuer/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useAsyncQueuer/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncRateLimiter/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncRateLimiter/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useAsyncRateLimiter/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useAsyncRateLimiter/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useAsyncRateLimiter/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useAsyncRateLimiter/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncThrottler/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useAsyncThrottler/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useAsyncThrottler/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useAsyncThrottler/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useAsyncThrottler/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useAsyncThrottler/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useBatcher/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useBatcher/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useBatcher/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useBatcher/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useBatcher/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useBatcher/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useDebouncedCallback/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useDebouncedCallback/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useDebouncedCallback/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useDebouncedCallback/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useDebouncedCallback/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useDebouncedCallback/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useDebouncedState/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useDebouncedState/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useDebouncedState/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useDebouncedState/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useDebouncedState/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useDebouncedState/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useDebouncedValue/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useDebouncedValue/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useDebouncedValue/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useDebouncedValue/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useDebouncedValue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useDebouncedValue/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useDebouncer/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useDebouncer/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useDebouncer/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useDebouncer/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useDebouncer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useDebouncer/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useQueuedState/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useQueuedState/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useQueuedState/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useQueuedState/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useQueuedState/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useQueuedState/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useQueuedValue/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useQueuedValue/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useQueuedValue/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useQueuedValue/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useQueuedValue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useQueuedValue/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useQueuer/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useQueuer/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useQueuer/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useQueuer/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useQueuer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useQueuer/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedCallback/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedCallback/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedCallback/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedCallback/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedCallback/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedCallback/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedState/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedState/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedState/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedState/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedState/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedState/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedValue/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedValue/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedValue/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedValue/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedValue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useRateLimitedValue/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useRateLimiter/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useRateLimiter/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useRateLimiter/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useRateLimiter/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useRateLimiter/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useRateLimiter/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useThrottledCallback/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useThrottledCallback/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useThrottledCallback/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useThrottledCallback/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useThrottledCallback/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useThrottledCallback/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useThrottledState/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useThrottledState/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useThrottledState/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useThrottledState/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useThrottledState/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useThrottledState/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useThrottledValue/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useThrottledValue/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useThrottledValue/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useThrottledValue/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useThrottledValue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useThrottledValue/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/react/useThrottler/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: ['plugin:react/recommended', 'plugin:react-hooks/recommended'], 7 | rules: { 8 | 'react/no-children-prop': 'off', 9 | }, 10 | }, 11 | } 12 | 13 | module.exports = config 14 | -------------------------------------------------------------------------------- /examples/react/useThrottler/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/react/useThrottler/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/react/useThrottler/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/react/useThrottler/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "react-jsx", 15 | 16 | /* Linting */ 17 | "strict": true, 18 | "noUnusedLocals": true, 19 | "noUnusedParameters": true, 20 | "noFallthroughCasesInSwitch": true 21 | }, 22 | "include": ["src", "vite.config.ts"] 23 | } 24 | -------------------------------------------------------------------------------- /examples/react/useThrottler/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import react from '@vitejs/plugin-react' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [ 7 | react({ 8 | // babel: { 9 | // plugins: [['babel-plugin-react-compiler', { target: '19' }]], 10 | // }, 11 | }), 12 | ], 13 | }) 14 | -------------------------------------------------------------------------------- /examples/solid/asyncDebounce/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/asyncDebounce/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/asyncDebounce/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/asyncDebounce/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/asyncDebounce/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-async-debounce", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/asyncDebounce/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/asyncDebounce/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/asyncRateLimit/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/asyncRateLimit/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/asyncRateLimit/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/asyncRateLimit/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/asyncRateLimit/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-async-rate-limit", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/asyncRateLimit/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/asyncRateLimit/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/asyncThrottle/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/asyncThrottle/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/asyncThrottle/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/asyncThrottle/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/asyncThrottle/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-async-throttle", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/asyncThrottle/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/asyncThrottle/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/batch/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/batch/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/batch/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/batch/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/batch/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-batch", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/batch/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/batch/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createAsyncDebouncer/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createAsyncDebouncer/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createAsyncDebouncer/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createAsyncDebouncer/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createAsyncDebouncer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createAsyncDebouncer/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createAsyncQueuer/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createAsyncQueuer/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createAsyncQueuer/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createAsyncQueuer/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createAsyncQueuer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createAsyncQueuer/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createAsyncRateLimiter/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createAsyncRateLimiter/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createAsyncRateLimiter/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createAsyncRateLimiter/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createAsyncRateLimiter/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createAsyncRateLimiter/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createAsyncThrottler/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createAsyncThrottler/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createAsyncThrottler/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createAsyncThrottler/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createAsyncThrottler/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createAsyncThrottler/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createBatcher/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createBatcher/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createBatcher/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createBatcher/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createBatcher/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-create-batcher", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/createBatcher/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createBatcher/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedSignal/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedSignal/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedSignal/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedSignal/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedSignal/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedSignal/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedValue/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedValue/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedValue/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedValue/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedValue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createDebouncedValue/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createDebouncer/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createDebouncer/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createDebouncer/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createDebouncer/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createDebouncer/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-create-debouncer", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/createDebouncer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createDebouncer/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createQueuer/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createQueuer/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createQueuer/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createQueuer/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createQueuer/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-create-queuer", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/createQueuer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createQueuer/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedSignal/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedSignal/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedSignal/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedSignal/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedSignal/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedSignal/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedValue/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedValue/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedValue/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedValue/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedValue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createRateLimitedValue/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createRateLimiter/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createRateLimiter/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createRateLimiter/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createRateLimiter/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createRateLimiter/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createRateLimiter/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createThrottledSignal/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createThrottledSignal/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createThrottledSignal/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createThrottledSignal/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createThrottledSignal/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createThrottledSignal/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createThrottledValue/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createThrottledValue/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createThrottledValue/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createThrottledValue/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createThrottledValue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createThrottledValue/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/createThrottler/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/createThrottler/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/createThrottler/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/createThrottler/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/createThrottler/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/createThrottler/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/debounce/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/debounce/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/debounce/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/debounce/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/debounce/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-debounce", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/debounce/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/debounce/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/queue/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/queue/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/queue/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/queue/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/queue/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-queue", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/queue/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/queue/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/rateLimit/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/rateLimit/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/rateLimit/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/rateLimit/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/rateLimit/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-rate-limit", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/rateLimit/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/rateLimit/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /examples/solid/throttle/.eslintrc.cjs: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('eslint').Linter.Config} */ 4 | const config = { 5 | settings: { 6 | extends: [], 7 | rules: {}, 8 | }, 9 | } 10 | 11 | module.exports = config 12 | -------------------------------------------------------------------------------- /examples/solid/throttle/.gitignore: -------------------------------------------------------------------------------- 1 | # See https://help.github.com/articles/ignoring-files/ for more about ignoring files. 2 | 3 | # dependencies 4 | /node_modules 5 | /.pnp 6 | .pnp.js 7 | 8 | # testing 9 | /coverage 10 | 11 | # production 12 | /build 13 | 14 | pnpm-lock.yaml 15 | yarn.lock 16 | package-lock.json 17 | 18 | # misc 19 | .DS_Store 20 | .env.local 21 | .env.development.local 22 | .env.test.local 23 | .env.production.local 24 | 25 | npm-debug.log* 26 | yarn-debug.log* 27 | yarn-error.log* 28 | -------------------------------------------------------------------------------- /examples/solid/throttle/README.md: -------------------------------------------------------------------------------- 1 | # Example 2 | 3 | To run this example: 4 | 5 | - `npm install` 6 | - `npm run dev` 7 | -------------------------------------------------------------------------------- /examples/solid/throttle/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | TanStack Pacer Example 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /examples/solid/throttle/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@tanstack/pacer-example-solid-throttle", 3 | "private": true, 4 | "type": "module", 5 | "scripts": { 6 | "dev": "vite --port=3005", 7 | "build": "vite build", 8 | "preview": "vite preview", 9 | "test:types": "tsc" 10 | }, 11 | "dependencies": { 12 | "@tanstack/solid-pacer": "^0.8.0", 13 | "solid-js": "^1.9.7" 14 | }, 15 | "devDependencies": { 16 | "vite": "^6.3.5", 17 | "vite-plugin-solid": "^2.11.6" 18 | }, 19 | "browserslist": { 20 | "production": [ 21 | ">0.2%", 22 | "not dead", 23 | "not op_mini all" 24 | ], 25 | "development": [ 26 | "last 1 chrome version", 27 | "last 1 firefox version", 28 | "last 1 safari version" 29 | ] 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /examples/solid/throttle/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "DOM.Iterable", "ESNext"], 5 | "module": "ESNext", 6 | "skipLibCheck": true, 7 | 8 | /* Bundler mode */ 9 | "moduleResolution": "Bundler", 10 | "allowImportingTsExtensions": true, 11 | "resolveJsonModule": true, 12 | "isolatedModules": true, 13 | "noEmit": true, 14 | "jsx": "preserve", 15 | "jsxImportSource": "solid-js", 16 | 17 | /* Linting */ 18 | "strict": true, 19 | "noUnusedLocals": true, 20 | "noUnusedParameters": true, 21 | "noFallthroughCasesInSwitch": true 22 | }, 23 | "include": ["src", "vite.config.ts"] 24 | } 25 | -------------------------------------------------------------------------------- /examples/solid/throttle/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | import solid from 'vite-plugin-solid' 3 | 4 | // https://vite.dev/config/ 5 | export default defineConfig({ 6 | plugins: [solid({})], 7 | }) 8 | -------------------------------------------------------------------------------- /knip.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://unpkg.com/knip@5/schema.json", 3 | "ignoreDependencies": ["@size-limit/preset-small-lib", "@faker-js/faker"], 4 | "ignoreWorkspaces": ["examples/**"], 5 | "workspaces": { 6 | "packages/react-pacer": { 7 | "ignore": [] 8 | } 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /packages/pacer/eslint.config.js: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | import rootConfig from '../../eslint.config.js' 4 | 5 | export default [ 6 | ...rootConfig, 7 | { 8 | rules: {}, 9 | }, 10 | ] 11 | -------------------------------------------------------------------------------- /packages/pacer/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from './async-debouncer' 2 | export * from './async-queuer' 3 | export * from './async-rate-limiter' 4 | export * from './async-throttler' 5 | export * from './batcher' 6 | export * from './compare' 7 | export * from './debouncer' 8 | export * from './queuer' 9 | export * from './rate-limiter' 10 | export * from './throttler' 11 | export * from './types' 12 | export * from './utils' 13 | -------------------------------------------------------------------------------- /packages/pacer/src/types.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Represents a function that can be called with any arguments and returns any value. 3 | */ 4 | export type AnyFunction = (...args: Array) => any 5 | 6 | /** 7 | * Represents an asynchronous function that can be called with any arguments and returns a promise. 8 | */ 9 | export type AnyAsyncFunction = (...args: Array) => Promise 10 | 11 | export type OptionalKeys = Omit & 12 | Partial> 13 | -------------------------------------------------------------------------------- /packages/pacer/tests/test-setup.ts: -------------------------------------------------------------------------------- 1 | import '@testing-library/jest-dom/vitest' 2 | -------------------------------------------------------------------------------- /packages/pacer/tsconfig.docs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig.json", 3 | "include": ["tests", "src"] 4 | } 5 | -------------------------------------------------------------------------------- /packages/pacer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../tsconfig.json", 3 | "include": ["src", "eslint.config.js", "vite.config.ts", "tests"] 4 | } 5 | -------------------------------------------------------------------------------- /packages/pacer/vite.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig, mergeConfig } from 'vitest/config' 2 | import { tanstackViteConfig } from '@tanstack/config/vite' 3 | import packageJson from './package.json' 4 | 5 | const config = defineConfig({ 6 | test: { 7 | name: packageJson.name, 8 | dir: './', 9 | watch: false, 10 | environment: 'jsdom', 11 | setupFiles: ['./tests/test-setup.ts'], 12 | globals: true, 13 | }, 14 | }) 15 | 16 | export default mergeConfig( 17 | config, 18 | tanstackViteConfig({ 19 | entry: ['./src/index.ts'], 20 | srcDir: './src', 21 | }), 22 | ) 23 | -------------------------------------------------------------------------------- /packages/react-pacer/src/async-debouncer/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the async-debouncer module 2 | export * from '@tanstack/pacer/async-debouncer' 3 | 4 | export * from './useAsyncDebouncer' 5 | -------------------------------------------------------------------------------- /packages/react-pacer/src/async-queuer/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/async-queuer' 2 | 3 | export * from './useAsyncQueuer' 4 | export * from './useAsyncQueuedState' 5 | -------------------------------------------------------------------------------- /packages/react-pacer/src/async-rate-limiter/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the async-rate-limiter module 2 | export * from '@tanstack/pacer/async-rate-limiter' 3 | 4 | export * from './useAsyncRateLimiter' 5 | -------------------------------------------------------------------------------- /packages/react-pacer/src/async-throttler/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the async-throttler module 2 | export * from '@tanstack/pacer/async-throttler' 3 | 4 | export * from './useAsyncThrottler' 5 | -------------------------------------------------------------------------------- /packages/react-pacer/src/batcher/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/batcher' 2 | 3 | export * from './useBatcher' 4 | -------------------------------------------------------------------------------- /packages/react-pacer/src/compare/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/compare' 2 | -------------------------------------------------------------------------------- /packages/react-pacer/src/debouncer/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the debouncer module 2 | export * from '@tanstack/pacer/debouncer' 3 | 4 | export * from './useDebouncedCallback' 5 | export * from './useDebouncedState' 6 | export * from './useDebouncedValue' 7 | export * from './useDebouncer' 8 | -------------------------------------------------------------------------------- /packages/react-pacer/src/queuer/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/queuer' 2 | 3 | export * from './useQueuer' 4 | export * from './useQueuedState' 5 | export * from './useQueuedValue' 6 | -------------------------------------------------------------------------------- /packages/react-pacer/src/rate-limiter/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/rate-limiter' 2 | 3 | export * from './useRateLimitedCallback' 4 | export * from './useRateLimiter' 5 | export * from './useRateLimitedState' 6 | export * from './useRateLimitedValue' 7 | -------------------------------------------------------------------------------- /packages/react-pacer/src/throttler/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the throttler module 2 | export * from '@tanstack/pacer/throttler' 3 | 4 | export * from './useThrottledCallback' 5 | export * from './useThrottledState' 6 | export * from './useThrottledValue' 7 | export * from './useThrottler' 8 | -------------------------------------------------------------------------------- /packages/react-pacer/src/types/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/types' 2 | -------------------------------------------------------------------------------- /packages/react-pacer/src/utils/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/utils' 2 | -------------------------------------------------------------------------------- /packages/react-pacer/tsconfig.docs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig.json", 3 | "compilerOptions": { 4 | "paths": { 5 | "@tanstack/pacer": ["../pacer/src"] 6 | } 7 | }, 8 | "include": ["src"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/react-pacer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../tsconfig.json", 3 | "compilerOptions": { 4 | "jsx": "react" 5 | }, 6 | "include": ["src", "eslint.config.js", "vite.config.ts", "tests"] 7 | } 8 | -------------------------------------------------------------------------------- /packages/solid-pacer/eslint.config.js: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | import rootConfig from '../../eslint.config.js' 4 | 5 | export default [ 6 | ...rootConfig, 7 | { 8 | files: ['**/*.{ts,tsx}'], 9 | }, 10 | { 11 | plugins: {}, 12 | rules: {}, 13 | }, 14 | { 15 | files: ['**/__tests__/**'], 16 | rules: {}, 17 | }, 18 | ] 19 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/async-debouncer/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the async-debouncer module 2 | export * from '@tanstack/pacer/async-debouncer' 3 | 4 | export * from './createAsyncDebouncer' 5 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/async-queuer/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/async-queuer' 2 | 3 | export * from './createAsyncQueuer' 4 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/async-rate-limiter/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the async-rate-limiter module 2 | export * from '@tanstack/pacer/async-rate-limiter' 3 | 4 | export * from './createAsyncRateLimiter' 5 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/async-throttler/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the async-throttler module 2 | export * from '@tanstack/pacer/async-throttler' 3 | 4 | export * from './createAsyncThrottler' 5 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/batcher/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/batcher' 2 | 3 | export * from './createBatcher' 4 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/compare/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/compare' 2 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/debouncer/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the debouncer module 2 | export * from '@tanstack/pacer/debouncer' 3 | 4 | export * from './createDebouncedSignal' 5 | export * from './createDebouncedValue' 6 | export * from './createDebouncer' 7 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/queuer/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/queuer' 2 | 3 | export * from './createQueuer' 4 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/rate-limiter/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/rate-limiter' 2 | 3 | export * from './createRateLimiter' 4 | export * from './createRateLimitedSignal' 5 | export * from './createRateLimitedValue' 6 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/throttler/index.ts: -------------------------------------------------------------------------------- 1 | // re-export everything from the core pacer package, BUT ONLY from the throttler module 2 | export * from '@tanstack/pacer/throttler' 3 | 4 | export * from './createThrottledSignal' 5 | export * from './createThrottledValue' 6 | export * from './createThrottler' 7 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/types/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/types' 2 | -------------------------------------------------------------------------------- /packages/solid-pacer/src/utils/index.ts: -------------------------------------------------------------------------------- 1 | export * from '@tanstack/pacer/utils' 2 | -------------------------------------------------------------------------------- /packages/solid-pacer/tsconfig.docs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig.json", 3 | "compilerOptions": { 4 | "paths": { 5 | "@tanstack/pacer": ["../pacer/src"] 6 | } 7 | }, 8 | "include": ["src"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/solid-pacer/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../tsconfig.json", 3 | "compilerOptions": { 4 | "jsx": "preserve", 5 | "jsxImportSource": "solid-js" 6 | }, 7 | "include": ["src", "eslint.config.js", "vite.config.ts", "tests"] 8 | } 9 | -------------------------------------------------------------------------------- /pnpm-workspace.yaml: -------------------------------------------------------------------------------- 1 | packages: 2 | - 'examples/**/*' 3 | - 'packages/*' 4 | -------------------------------------------------------------------------------- /prettier.config.js: -------------------------------------------------------------------------------- 1 | // @ts-check 2 | 3 | /** @type {import('prettier').Config} */ 4 | const config = { 5 | semi: false, 6 | singleQuote: true, 7 | trailingComma: 'all', 8 | plugins: ['prettier-plugin-svelte'], 9 | overrides: [{ files: '*.svelte', options: { parser: 'svelte' } }], 10 | } 11 | 12 | export default config 13 | -------------------------------------------------------------------------------- /vitest.workspace.js: -------------------------------------------------------------------------------- 1 | import { defineWorkspace } from 'vitest/config' 2 | 3 | export default defineWorkspace([ 4 | './packages/pacer/vite.config.ts', 5 | './packages/react-pacer/vite.config.ts', 6 | './packages/solid-pacer/vite.config.ts', 7 | ]) 8 | --------------------------------------------------------------------------------