@xylabs/axios 5.0.95 → 5.0.97

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 +56 -86
  2. package/package.json +13 -11
package/README.md CHANGED
@@ -1,50 +1,52 @@
1
1
  # @xylabs/axios
2
2
 
3
- [![logo][]](https://xylabs.com)
3
+ [![npm][npm-badge]][npm-link]
4
+ [![license][license-badge]][license-link]
4
5
 
5
- [![main-build][]][main-build-link]
6
- [![npm-badge][]][npm-link]
7
- [![npm-downloads-badge][]][npm-link]
8
- [![jsdelivr-badge][]][jsdelivr-link]
9
- [![npm-license-badge][]](LICENSE)
10
- [![codacy-badge][]][codacy-link]
11
- [![codeclimate-badge][]][codeclimate-link]
12
- [![snyk-badge][]][snyk-link]
13
- [![socket-badge][]][socket-link]
6
+ > Base functionality used throughout XY Labs TypeScript/JavaScript libraries
14
7
 
8
+ ## Install
15
9
 
16
- Base functionality used throughout XY Labs TypeScript/JavaScript libraries
10
+ Using npm:
17
11
 
12
+ ```sh
13
+ npm install {{name}}
14
+ ```
18
15
 
16
+ Using yarn:
19
17
 
20
- ## Reference
18
+ ```sh
19
+ yarn add {{name}}
20
+ ```
21
21
 
22
- **@xylabs/axios**
22
+ Using pnpm:
23
23
 
24
- ***
24
+ ```sh
25
+ pnpm add {{name}}
26
+ ```
25
27
 
26
- ## Classes
28
+ Using bun:
27
29
 
28
- | Class | Description |
29
- | ------ | ------ |
30
- | [~~AxiosJson~~](#classes/AxiosJson) | - |
30
+ ```sh
31
+ bun add {{name}}
32
+ ```
31
33
 
32
- ## Variables
33
34
 
34
- | Variable | Description |
35
- | ------ | ------ |
36
- | [axiosJson](#variables/axiosJson) | - |
37
- | [~~axios~~](#variables/axios) | - |
35
+ ## License
38
36
 
39
- ## Functions
37
+ See the [LICENSE](LICENSE) file for license rights and limitations (LGPL-3.0-only).
40
38
 
41
- | Function | Description |
42
- | ------ | ------ |
43
- | [axiosJsonConfig](#functions/axiosJsonConfig) | Creates an Axios config preconfigured for JSON requests with optional gzip compression. Request bodies exceeding `compressLength` (default 1024 bytes) are automatically gzip-compressed. |
39
+ ## Reference
44
40
 
45
- ### classes
41
+ ### packages
46
42
 
47
- ### <a id="AxiosJson"></a>AxiosJson
43
+ ### axios
44
+
45
+ ### .temp-typedoc
46
+
47
+ ### classes
48
+
49
+ ### <a id="AxiosJson"></a>AxiosJson
48
50
 
49
51
  [**@xylabs/axios**](#../README)
50
52
 
@@ -63,14 +65,14 @@ use axiosJsonConfig instead
63
65
  ### Constructor
64
66
 
65
67
  ```ts
66
- new AxiosJson(config?: RawAxiosJsonRequestConfig): AxiosJson;
68
+ new AxiosJson(config?): AxiosJson;
67
69
  ```
68
70
 
69
71
  ### Parameters
70
72
 
71
- | Parameter | Type |
72
- | ------ | ------ |
73
- | `config?` | `RawAxiosJsonRequestConfig` |
73
+ #### config?
74
+
75
+ `RawAxiosJsonRequestConfig`
74
76
 
75
77
  ### Returns
76
78
 
@@ -87,14 +89,14 @@ Axios.constructor
87
89
  ### ~~axiosConfig()~~
88
90
 
89
91
  ```ts
90
- static axiosConfig(config?: RawAxiosJsonRequestConfig): RawAxiosJsonRequestConfig;
92
+ static axiosConfig(config?): RawAxiosJsonRequestConfig;
91
93
  ```
92
94
 
93
95
  ### Parameters
94
96
 
95
- | Parameter | Type |
96
- | ------ | ------ |
97
- | `config` | `RawAxiosJsonRequestConfig` |
97
+ #### config?
98
+
99
+ `RawAxiosJsonRequestConfig` = `{}`
98
100
 
99
101
  ### Returns
100
102
 
@@ -105,29 +107,29 @@ static axiosConfig(config?: RawAxiosJsonRequestConfig): RawAxiosJsonRequestConfi
105
107
  ### ~~create()~~
106
108
 
107
109
  ```ts
108
- static create(config?: RawAxiosJsonRequestConfig): Axios;
110
+ static create(config?): Axios;
109
111
  ```
110
112
 
111
113
  ### Parameters
112
114
 
113
- | Parameter | Type |
114
- | ------ | ------ |
115
- | `config?` | `RawAxiosJsonRequestConfig` |
115
+ #### config?
116
+
117
+ `RawAxiosJsonRequestConfig`
116
118
 
117
119
  ### Returns
118
120
 
119
121
  `Axios`
120
122
 
121
- ### functions
123
+ ### functions
122
124
 
123
- ### <a id="axiosJsonConfig"></a>axiosJsonConfig
125
+ ### <a id="axiosJsonConfig"></a>axiosJsonConfig
124
126
 
125
127
  [**@xylabs/axios**](#../README)
126
128
 
127
129
  ***
128
130
 
129
131
  ```ts
130
- function axiosJsonConfig(config?: RawAxiosJsonRequestConfig): RawAxiosJsonRequestConfig;
132
+ function axiosJsonConfig(config?): RawAxiosJsonRequestConfig;
131
133
  ```
132
134
 
133
135
  Creates an Axios config preconfigured for JSON requests with optional gzip compression.
@@ -135,9 +137,11 @@ Request bodies exceeding `compressLength` (default 1024 bytes) are automatically
135
137
 
136
138
  ## Parameters
137
139
 
138
- | Parameter | Type | Description |
139
- | ------ | ------ | ------ |
140
- | `config` | `RawAxiosJsonRequestConfig` | Base Axios config, optionally including a `compressLength` threshold |
140
+ ### config?
141
+
142
+ `RawAxiosJsonRequestConfig` = `{}`
143
+
144
+ Base Axios config, optionally including a `compressLength` threshold
141
145
 
142
146
  ## Returns
143
147
 
@@ -145,9 +149,9 @@ Request bodies exceeding `compressLength` (default 1024 bytes) are automatically
145
149
 
146
150
  A fully configured Axios request config with JSON transforms
147
151
 
148
- ### variables
152
+ ### variables
149
153
 
150
- ### <a id="axios"></a>axios
154
+ ### <a id="axios"></a>axios
151
155
 
152
156
  [**@xylabs/axios**](#../README)
153
157
 
@@ -161,7 +165,7 @@ const axios: Axios = axiosJson;
161
165
 
162
166
  use axiosJson instead
163
167
 
164
- ### <a id="axiosJson"></a>axiosJson
168
+ ### <a id="axiosJson"></a>axiosJson
165
169
 
166
170
  [**@xylabs/axios**](#../README)
167
171
 
@@ -172,41 +176,7 @@ const axiosJson: Axios;
172
176
  ```
173
177
 
174
178
 
175
- Part of [sdk-js](https://www.npmjs.com/package/@xyo-network/sdk-js)
176
-
177
- ## Maintainers
178
-
179
- - [Arie Trouw](https://github.com/arietrouw) ([arietrouw.com](https://arietrouw.com))
180
- - [Matt Jones](https://github.com/jonesmac)
181
- - [Joel Carter](https://github.com/JoelBCarter)
182
- - [Jordan Trouw](https://github.com/jordantrouw)
183
-
184
- ## License
185
-
186
- > See the [LICENSE](LICENSE) file for license details
187
-
188
- ## Credits
189
-
190
- [Made with 🔥 and ❄️ by XYLabs](https://xylabs.com)
191
-
192
- [logo]: https://cdn.xy.company/img/brand/XYPersistentCompany_Logo_Icon_Colored.svg
193
-
194
- [main-build]: https://github.com/xylabs/sdk-js/actions/workflows/build.yml/badge.svg
195
- [main-build-link]: https://github.com/xylabs/sdk-js/actions/workflows/build.yml
196
179
  [npm-badge]: https://img.shields.io/npm/v/@xylabs/axios.svg
197
180
  [npm-link]: https://www.npmjs.com/package/@xylabs/axios
198
- [codacy-badge]: https://app.codacy.com/project/badge/Grade/c8e15e14f37741c18cfb47ac7245c698
199
- [codacy-link]: https://www.codacy.com/gh/xylabs/sdk-js/dashboard?utm_source=github.com&utm_medium=referral&utm_content=xylabs/sdk-js&utm_campaign=Badge_Grade
200
- [codeclimate-badge]: https://api.codeclimate.com/v1/badges/c5eb068f806f0b047ea7/maintainability
201
- [codeclimate-link]: https://codeclimate.com/github/xylabs/sdk-js/maintainability
202
- [snyk-badge]: https://snyk.io/test/github/xylabs/sdk-js/badge.svg?targetFile=package.json
203
- [snyk-link]: https://snyk.io/test/github/xylabs/sdk-js?targetFile=package.json
204
-
205
- [npm-downloads-badge]: https://img.shields.io/npm/dw/@xylabs/axios
206
- [npm-license-badge]: https://img.shields.io/npm/l/@xylabs/axios
207
-
208
- [jsdelivr-badge]: https://data.jsdelivr.com/v1/package/npm/@xylabs/axios/badge
209
- [jsdelivr-link]: https://www.jsdelivr.com/package/npm/@xylabs/axios
210
-
211
- [socket-badge]: https://socket.dev/api/badge/npm/package/@xylabs/axios
212
- [socket-link]: https://socket.dev/npm/package/@xylabs/axios
181
+ [license-badge]: https://img.shields.io/npm/l/@xylabs/axios.svg
182
+ [license-link]: https://github.com/xylabs/sdk-js/blob/main/LICENSE
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xylabs/axios",
3
- "version": "5.0.95",
3
+ "version": "5.0.97",
4
4
  "description": "Base functionality used throughout XY Labs TypeScript/JavaScript libraries",
5
5
  "keywords": [
6
6
  "axios",
@@ -29,12 +29,10 @@
29
29
  "exports": {
30
30
  ".": {
31
31
  "types": "./dist/neutral/index.d.ts",
32
- "import": "./dist/neutral/index.mjs",
33
32
  "default": "./dist/neutral/index.mjs"
34
33
  },
35
34
  "./package.json": "./package.json"
36
35
  },
37
- "types": "./dist/neutral/index.d.ts",
38
36
  "files": [
39
37
  "dist",
40
38
  "!**/*.bench.*",
@@ -46,21 +44,25 @@
46
44
  "pako": "~2.1.0"
47
45
  },
48
46
  "devDependencies": {
49
- "@types/node": "^25.5.2",
47
+ "@types/node": "^25.6.0",
50
48
  "@types/pako": "~2.0.4",
51
- "@xylabs/ts-scripts-common": "~7.8.4",
52
- "@xylabs/ts-scripts-pnpm": "~7.8.4",
53
- "@xylabs/tsconfig": "~7.8.4",
54
- "axios": "^1.14.0",
49
+ "@xylabs/toolchain": "~7.10.4",
50
+ "@xylabs/tsconfig": "~7.10.4",
51
+ "axios": "^1.15.0",
55
52
  "esbuild": "^0.28.0",
56
53
  "typescript": "^5",
57
- "vite": "^8.0.5",
58
- "vitest": "^4.1.2",
59
- "@xylabs/logger": "~5.0.95"
54
+ "vite": "^8.0.8",
55
+ "vitest": "^4.1.4",
56
+ "@xylabs/logger": "~5.0.97"
60
57
  },
61
58
  "peerDependencies": {
62
59
  "axios": "^1"
63
60
  },
61
+ "peerDependenciesMeta": {
62
+ "axios": {
63
+ "optional": true
64
+ }
65
+ },
64
66
  "engines": {
65
67
  "node": ">=18"
66
68
  },