Commit 3128284
committed
docs: Remove unverified Timeout Middleware example
Removed the Timeout Middleware example that was not found in the codebase:
- The pattern was unverified and potentially had memory leaks (no timeout cleanup)
- Used unnecessary middleware complexity
Replaced with correct approach using signal option directly:
- DevupApiRequestInit extends RequestInit, so signal is natively supported
- Added two examples: wrapper function and direct signal usage
- Includes proper timeout cleanup with clearTimeout()
- Simpler, clearer, and verified approach
This matches how React Query integration uses signal (see packages/react-query/src/query-client.ts:88-94)1 parent 97970e6 commit 3128284
1 file changed
+46
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
576 | 576 | | |
577 | 577 | | |
578 | 578 | | |
579 | | - | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
580 | 582 | | |
581 | 583 | | |
582 | 584 | | |
583 | 585 | | |
584 | 586 | | |
585 | 587 | | |
586 | | - | |
587 | | - | |
588 | | - | |
589 | | - | |
590 | | - | |
591 | | - | |
592 | | - | |
593 | | - | |
594 | | - | |
595 | | - | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
596 | 597 | | |
597 | | - | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
598 | 608 | | |
599 | | - | |
| 609 | + | |
600 | 610 | | |
601 | 611 | | |
602 | 612 | | |
603 | | - | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
| 625 | + | |
| 626 | + | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
| 633 | + | |
| 634 | + | |
604 | 635 | | |
605 | 636 | | |
606 | 637 | | |
607 | 638 | | |
| 639 | + | |
608 | 640 | | |
609 | 641 | | |
610 | 642 | | |
| |||
0 commit comments