create-request 0.0.1-beta.17 → 0.0.1-beta.18

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +23 -25
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -18,6 +18,7 @@
18
18
  - [CSRF Protection](#csrf-protection)
19
19
  - [Performance Considerations](#performance-considerations)
20
20
  - [Browser Support](#browser-support)
21
+ - [Comparison of JavaScript HTTP Client Libraries](#comparison-of-javascript-http-client-libraries)
21
22
  - [License](#license)
22
23
 
23
24
  ## Core Features
@@ -554,34 +555,31 @@ This library works with all browsers that support the Fetch API:
554
555
 
555
556
  ## Comparison of JavaScript HTTP Client Libraries
556
557
 
557
- Below is a comparison of popular JavaScript HTTP client libraries, including create-request and the native Fetch API.
558
-
559
- | Feature | create-request | Fetch API | Axios | SuperAgent | Got | Ky | node-fetch | Redaxios |
560
- | -------------------------- | -------------- | -------------------- | ----------------- | ----------- | ------------------ | ----------- | ---------------- | -------------------- |
561
- | **Bundle Size (min+gzip)** | ~5.1KB | Native | ~13.6KB | ~17.8KB | ~17.8KB | ~3.4KB | ~ 7.7KB | ~1KB |
562
- | **Browser Support** | Modern | Modern | IE11+ | IE9+ | ❌ No Browser | Modern | ❌ No Browser | Modern |
563
- | **Node.js Support** | Polyfill | Node 18+ | ✅ | ✅ | ✅ | ✅ + undici | ✅ | ✅ |
564
- | **HTTP/2 Support** | Via Fetch | Platform-dependent | ❌ | ✅ | ✅ | ✅ | ❌ | ❌ |
565
- | **Automatic Retries** | ✅ | ❌ | ❌ + addon | ✅ | ✅ | ✅ | ❌ | ❌ |
566
- | **Request Cancellation** | ✅ | ✅ (AbortController) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ (AbortController) |
567
- | **Response Caching** | ✅ | ❌ | ❌ + addon | ✅ | ✅ (RFC compliant) | ❌ | ❌ | ❌ |
568
- | **Automatic JSON** | ✅ | ❌ (Manual) | ✅ | ✅ | ✅ | ✅ | ❌ (Manual) | ✅ |
569
- | **Timeout Handling** | ✅ | ❌ | ✅ | ✅ | ✅ (Advanced) | ✅ | ✅ (AbortSignal) | ❌ |
570
- | **TypeScript Support** | First-class | ✅ | ✅ | ✅ (via DT) | ✅ | ✅ | ✅ | ✅ |
571
- | **Streaming** | Via Fetch | ✅ | ❌ | ✅ | ✅ | ❌ | ✅ (Node only) | ❌ |
572
- | **Progress Events** | ❌ | ❌ | ✅ (Browser) | ✅ | ✅ | ✅ | ❌ | ❌ |
573
- | **Hooks/Middleware** | ❌ | ❌ | ✅ (Interceptors) | ❌ | ✅ | ✅ | ❌ | ❌ |
574
- | **Cookies Built-in** | ✅ | ❌ | ❌ | ✅ | ✅ | ❌ | ❌ | ❌ |
575
- | **Pagination API** | ❌ | ❌ | ❌ | ❌ | ✅ | ❌ | ❌ | ❌ |
576
- | **Zero Dependencies** | ✅ | ✅ | ❌ | ❌ | ❌ | ✅ | ✅ | ✅ |
577
- | **Fluent/Chainable API** | ✅ | ❌ | ❌ | ✅ | ✅ | ❌ | ❌ | ❌ |
578
- | **CSRF Protection** | ✅ | ❌ | ✅ | ❌ | ❌ | ❌ | ❌ | ❌ |
558
+ | Feature | create-request | Fetch | Axios | SuperAgent | Got | Ky | node-fetch | Redaxios |
559
+ | ------------------- | -------------- | ------ | ------- | ---------- | ------- | ------ | ---------- | -------- |
560
+ | **Size (min+gzip)** | ~5.1KB | Native | ~13.6KB | ~17.8KB | ~17.8KB | ~3.4KB | ~7.7KB | ~1KB |
561
+ | **Browser** | Modern | Modern | IE11+ | IE9+ | ❌ No | Modern | ❌ No | Modern |
562
+ | **Node.js** | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
563
+ | **HTTP/2** | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ |
564
+ | **Auto Retries** | ✅ | ❌ | 🛠️ | ✅ | ✅ | ✅ | ❌ | ❌ |
565
+ | **Cancellation** | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
566
+ | **Caching** | ✅ | ❌ | ❌ | ✅ | ✅ | ❌ | ❌ | ❌ |
567
+ | **Auto JSON** | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ❌ | ✅ |
568
+ | **Timeout** | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
569
+ | **TypeScript** | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
570
+ | **Streaming** | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ |
571
+ | **Progress** | ❌ | ❌ | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ |
572
+ | **Middleware** | ❌ | ❌ | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ |
573
+ | **Cookies** | ✅ | ✅ | 🛠️ | ✅ | ✅ | ❌ | ❌ | ❌ |
574
+ | **Pagination API** | ❌ | ❌ | ❌ | ❌ | ✅ | ❌ | ❌ | ❌ |
575
+ | **Zero Deps** | ✅ | ✅ | ❌ | ❌ | ❌ | ✅ | ✅ | ✅ |
576
+ | **Chainable API** | ✅ | ❌ | ❌ | ✅ | ✅ | ✅ | ❌ | ❌ |
577
+ | **CSRF Protection** | ✅ | ❌ | ✅ | ❌ | ❌ | ❌ | ❌ | ❌ |
579
578
 
580
579
  **Notes:**
581
580
 
582
- - Bundle sizes are approximate and may vary based on build configuration.
583
- - "Automatic JSON" refers to automatic parsing of JSON responses.
584
- - "CSRF Protection" refers to built-in mechanisms for CSRF defense.
581
+ - "Modern" browser support: Chrome 42+, Firefox 39+, Safari 10.1+, Edge 14+, Opera 29+
582
+ - 🛠️ Feature requires additional plugins or adapters (not available out-of-the-box)
585
583
 
586
584
  ## License
587
585
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-request",
3
- "version": "0.0.1-beta.17",
3
+ "version": "0.0.1-beta.18",
4
4
  "description": "A modern, chainable wrapper for fetch with automatic retries, timeouts, comprehensive error handling, and first-class TypeScript support",
5
5
  "main": "dist/library/index.js",
6
6
  "module": "dist/library/index.esm.js",