@decoraxios/awe-axios-core 0.3.0 → 0.4.0
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.
- package/CHANGELOG.md +14 -0
- package/README.md +2 -34
- package/index.cjs +1 -0
- package/index.d.ts +1 -0
- package/index.js +1 -0
- package/package.json +15 -15
- package/dist/index.cjs +0 -851
- package/dist/index.cjs.map +0 -1
- package/dist/index.d.cts +0 -102
- package/dist/index.d.ts +0 -102
- package/dist/index.js +0 -782
- package/dist/index.js.map +0 -1
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# @decoraxios/awe-axios-core
|
|
2
|
+
|
|
3
|
+
## 0.4.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 4db6829: Unify the published package family around `decoraxios` and `@decoraxios/*`, while keeping the previous `awe-axios` and `@decoraxios/awe-axios-*` names as compatibility aliases.
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [4db6829]
|
|
12
|
+
- @decoraxios/core@0.4.0
|
|
13
|
+
|
|
14
|
+
This package is maintained as a compatibility alias for `@decoraxios/core`.
|
package/README.md
CHANGED
|
@@ -1,37 +1,5 @@
|
|
|
1
1
|
# @decoraxios/awe-axios-core
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Compatibility alias package for `@decoraxios/core`.
|
|
4
4
|
|
|
5
|
-
`@decoraxios/
|
|
6
|
-
|
|
7
|
-
## Install
|
|
8
|
-
|
|
9
|
-
```bash
|
|
10
|
-
npm install @decoraxios/awe-axios-core axios
|
|
11
|
-
```
|
|
12
|
-
|
|
13
|
-
## Highlights
|
|
14
|
-
|
|
15
|
-
- Decorator-based HTTP client declarations
|
|
16
|
-
- Strong TypeScript return types
|
|
17
|
-
- Request strategy decorators such as `@Retry`, `@Debounce`, and `@Throttle`
|
|
18
|
-
- Custom axios instance binding and request/response transforms
|
|
19
|
-
|
|
20
|
-
## Quick Example
|
|
21
|
-
|
|
22
|
-
```ts
|
|
23
|
-
import { type ApiCall, Get, HttpApi, PathParam } from '@decoraxios/awe-axios-core';
|
|
24
|
-
|
|
25
|
-
@HttpApi('https://api.example.com/users')
|
|
26
|
-
class UserApi {
|
|
27
|
-
@Get('/:id')
|
|
28
|
-
getUser(@PathParam('id') id: string): ApiCall<{ id: string; name: string }> {
|
|
29
|
-
return undefined as never;
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
```
|
|
33
|
-
|
|
34
|
-
More documentation:
|
|
35
|
-
|
|
36
|
-
- English: <https://github.com/bloom-lmh/awe-axios#readme>
|
|
37
|
-
- 中文: <https://github.com/bloom-lmh/awe-axios/blob/master/README_CH.md>
|
|
5
|
+
New projects should install `@decoraxios/core` directly.
|
package/index.cjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
module.exports = require('@decoraxios/core');
|
package/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@decoraxios/core';
|
package/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@decoraxios/core';
|
package/package.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@decoraxios/awe-axios-core",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "0.4.0",
|
|
4
|
+
"description": "Compatibility alias for @decoraxios/core",
|
|
5
5
|
"author": "SWUST-LMH <1357526355@qq.com>",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"type": "module",
|
|
8
|
-
"main": "./
|
|
9
|
-
"module": "./
|
|
10
|
-
"types": "./
|
|
8
|
+
"main": "./index.cjs",
|
|
9
|
+
"module": "./index.js",
|
|
10
|
+
"types": "./index.d.ts",
|
|
11
11
|
"repository": {
|
|
12
12
|
"type": "git",
|
|
13
13
|
"url": "https://github.com/bloom-lmh/awe-axios.git"
|
|
@@ -24,9 +24,9 @@
|
|
|
24
24
|
],
|
|
25
25
|
"exports": {
|
|
26
26
|
".": {
|
|
27
|
-
"types": "./
|
|
28
|
-
"import": "./
|
|
29
|
-
"require": "./
|
|
27
|
+
"types": "./index.d.ts",
|
|
28
|
+
"import": "./index.js",
|
|
29
|
+
"require": "./index.cjs"
|
|
30
30
|
},
|
|
31
31
|
"./package.json": "./package.json"
|
|
32
32
|
},
|
|
@@ -37,18 +37,18 @@
|
|
|
37
37
|
"node": ">=18"
|
|
38
38
|
},
|
|
39
39
|
"files": [
|
|
40
|
-
"
|
|
40
|
+
"index.js",
|
|
41
|
+
"index.cjs",
|
|
42
|
+
"index.d.ts",
|
|
41
43
|
"README.md",
|
|
44
|
+
"CHANGELOG.md",
|
|
42
45
|
"LICENSE"
|
|
43
46
|
],
|
|
44
47
|
"sideEffects": false,
|
|
45
|
-
"
|
|
46
|
-
"
|
|
48
|
+
"dependencies": {
|
|
49
|
+
"@decoraxios/core": "^0.4.0"
|
|
47
50
|
},
|
|
48
|
-
"
|
|
51
|
+
"peerDependencies": {
|
|
49
52
|
"axios": "^1.11.0"
|
|
50
|
-
},
|
|
51
|
-
"scripts": {
|
|
52
|
-
"build": "tsup --config tsup.config.ts"
|
|
53
53
|
}
|
|
54
54
|
}
|