@holidays-rest/sdk-ts 1.1.0 → 1.13.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/README.md +6 -4
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -14,13 +14,15 @@ Official TypeScript SDK for the [holidays.rest](https://www.holidays.rest) API.
|
|
|
14
14
|
## Installation
|
|
15
15
|
|
|
16
16
|
```bash
|
|
17
|
-
npm
|
|
17
|
+
npm i @holidays-rest/sdk-ts
|
|
18
|
+
# or
|
|
19
|
+
yarn add @holidays-rest/sdk-ts
|
|
18
20
|
```
|
|
19
21
|
|
|
20
22
|
## Quick Start
|
|
21
23
|
|
|
22
24
|
```ts
|
|
23
|
-
import { HolidaysClient } from "holidays
|
|
25
|
+
import { HolidaysClient } from "@holidays-rest/sdk-ts";
|
|
24
26
|
|
|
25
27
|
const client = new HolidaysClient({ apiKey: "YOUR_API_KEY" });
|
|
26
28
|
|
|
@@ -126,7 +128,7 @@ import type {
|
|
|
126
128
|
Language,
|
|
127
129
|
HolidaysParams,
|
|
128
130
|
ClientOptions,
|
|
129
|
-
} from "holidays
|
|
131
|
+
} from "@holidays-rest/sdk-ts";
|
|
130
132
|
```
|
|
131
133
|
|
|
132
134
|
```ts
|
|
@@ -168,7 +170,7 @@ interface Language { code: string; name: string; }
|
|
|
168
170
|
Non-2xx responses throw `HolidaysApiError`:
|
|
169
171
|
|
|
170
172
|
```ts
|
|
171
|
-
import { HolidaysClient, HolidaysApiError } from "holidays
|
|
173
|
+
import { HolidaysClient, HolidaysApiError } from "@holidays-rest/sdk-ts";
|
|
172
174
|
|
|
173
175
|
try {
|
|
174
176
|
await client.getHolidays({ country: "US", year: 2024 });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@holidays-rest/sdk-ts",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.13.0",
|
|
4
4
|
"description": "Official TypeScript SDK for the holidays.rest API",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -40,15 +40,15 @@
|
|
|
40
40
|
"author": "msdundar",
|
|
41
41
|
"license": "MIT",
|
|
42
42
|
"engines": {
|
|
43
|
-
"node": ">=
|
|
43
|
+
"node": ">=22.0.0"
|
|
44
44
|
},
|
|
45
45
|
"repository": {
|
|
46
46
|
"url": "https://github.com/holidays-rest/sdk-ts"
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
|
-
"@vitest/coverage-v8": "^
|
|
49
|
+
"@vitest/coverage-v8": "^5.0.0",
|
|
50
50
|
"tsup": "^8.0.0",
|
|
51
|
-
"typescript": "^6.0.
|
|
52
|
-
"vitest": "^
|
|
51
|
+
"typescript": "^6.0.3",
|
|
52
|
+
"vitest": "^5.0.0"
|
|
53
53
|
}
|
|
54
54
|
}
|