node-csfd-api 2.7.10 → 2.7.12

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 CHANGED
@@ -3,14 +3,14 @@
3
3
  [![Build & Publish](https://github.com/bartholomej/node-csfd-api/workflows/Publish/badge.svg)](https://github.com/bartholomej/node-csfd-api/actions)
4
4
  [![codecov](https://codecov.io/gh/bartholomej/node-csfd-api/branch/master/graph/badge.svg?token=YQH9UoVrGP)](https://codecov.io/gh/bartholomej/node-csfd-api)
5
5
 
6
- # CSFD API 2023
6
+ # CSFD API 🎥 2024
7
7
 
8
8
  > JavaScript NPM library for scraping **Czech Movie Database (csfd.cz)**
9
9
  >
10
10
  > - JavaScript / TypeScript
11
11
  > - Browser + Node.js (SSR)
12
12
  > - Tested (~100% Code coverage)
13
- > - ✅ Ready for new ČSFD 2021!
13
+ > - ✅ Ready for new ČSFD 2024!
14
14
  > - You can use in:
15
15
  > - Firebase function
16
16
  > - AWS λ (lambda function)
@@ -19,14 +19,14 @@
19
19
  > - React native app
20
20
  > - Browsers (Pay attention to CORS)
21
21
 
22
- ## Install
22
+ ## 🗜️ Install
23
23
 
24
24
  ```bash
25
- npm install node-csfd-api --save
25
+ npm install node-csfd-api
26
26
  # yarn add node-csfd-api
27
27
  ```
28
28
 
29
- ## Usage and examples
29
+ ## 🛠️ Usage and examples
30
30
 
31
31
  - [Movies and TV Series](#Movie)
32
32
  - [User Ratings](#User-Ratings)
@@ -35,7 +35,7 @@ npm install node-csfd-api --save
35
35
 
36
36
  ### Movie
37
37
 
38
- Get info about [this movie](https://www.csfd.cz/film/535121-na-spatne-strane/komentare/) _(id: 535121)_
38
+ > Get info about [this movie](https://www.csfd.cz/film/535121-na-spatne-strane/komentare/) _(id: 535121)_
39
39
 
40
40
  ```javascript
41
41
  import { csfd } from 'node-csfd-api';
@@ -43,8 +43,9 @@ import { csfd } from 'node-csfd-api';
43
43
  csfd.movie(535121).then((movie) => console.log(movie));
44
44
  ```
45
45
 
46
- #### Results
47
-
46
+ <details>
47
+ <summary>Click here to see full result example</summary>
48
+
48
49
  ```javascript
49
50
  {
50
51
  id: 535121,
@@ -136,6 +137,7 @@ csfd.movie(535121).then((movie) => console.log(movie));
136
137
  ]
137
138
  }
138
139
  ```
140
+ </details>
139
141
 
140
142
  ### Search
141
143
 
@@ -147,10 +149,11 @@ import { csfd } from 'node-csfd-api';
147
149
  csfd.search('bart').then((search) => console.log(search));
148
150
  ```
149
151
 
150
- #### Results
151
-
152
+ <details>
153
+ <summary>Click here to see full result example</summary>
154
+
152
155
  ```javascript
153
- movies: [
156
+ [
154
157
  {
155
158
  id: 19653,
156
159
  title: 'Black Bart',
@@ -198,6 +201,8 @@ users: [
198
201
  ]
199
202
  ```
200
203
 
204
+ </details>
205
+
201
206
  ### Creators
202
207
 
203
208
  > Get creator info + filmography
@@ -208,7 +213,8 @@ import { csfd } from 'node-csfd-api';
208
213
  csfd.creator(2120).then((creator) => console.log(creator));
209
214
  ```
210
215
 
211
- #### Results
216
+ <details>
217
+ <summary>Click here to see full result example</summary>
212
218
 
213
219
  ```javascript
214
220
  {
@@ -285,6 +291,8 @@ csfd.creator(2120).then((creator) => console.log(creator));
285
291
  }
286
292
  ```
287
293
 
294
+ </details>
295
+
288
296
  ### User Ratings
289
297
 
290
298
  #### Last ratings (last page)
@@ -314,7 +322,8 @@ csfd
314
322
  .then((ratings) => console.log(ratings));
315
323
  ```
316
324
 
317
- #### Results
325
+ <details>
326
+ <summary>Click here to see full result example</summary>
318
327
 
319
328
  ```javascript
320
329
  [
@@ -339,7 +348,9 @@ csfd
339
348
  ];
340
349
  ```
341
350
 
342
- #### Options
351
+ </details>
352
+
353
+ #### Options for user ratings
343
354
 
344
355
  | Option | Type | Default | Description |
345
356
  | ----------------- | ------------------------------------------------------------------------------------------------------------------------------------------ | ------- | ------------------------------------------------------ |
@@ -348,9 +359,9 @@ csfd
348
359
  | **allPages** | boolean | false | Get all pages |
349
360
  | **allPagesDelay** | number | 0 | Delay on each page request. In milliseconds |
350
361
 
351
- _Note: You can not use both parameters 'includesOnly' and 'excludes'. Parameter 'includesOnly' has a priority._
362
+ _Note: You can not use both parameters `includesOnly` and `excludes`. Parameter `includesOnly` has a priority._
352
363
 
353
- ## Used by
364
+ ## 🧑‍💻 Used by
354
365
 
355
366
  ### Web extensions
356
367
 
@@ -364,9 +375,9 @@ _Note: You can not use both parameters 'includesOnly' and 'excludes'. Parameter
364
375
 
365
376
  ### Mobile applications
366
377
 
367
- - KinoKlub – Mobile application for AeroFilms (React Native: Android + iOS application)
378
+ - [KinoKlub](https://play.google.com/store/apps/details?id=com.aquasoup) – Mobile application for AeroFilms (React Native: Android + iOS application)
368
379
 
369
- ## Roadmap
380
+ ## 🔮 Roadmap
370
381
 
371
382
  ### Scraping more pages
372
383
 
@@ -414,7 +425,7 @@ _Note: You can not use both parameters 'includesOnly' and 'excludes'. Parameter
414
425
  - [x] Last ratings
415
426
  - [x] All pages
416
427
 
417
- ## Development
428
+ ## 🛠️ Development
418
429
 
419
430
  ### Developing and debugging library
420
431
 
@@ -430,22 +441,7 @@ You can find and modify it in [`./demo.ts`](https://github.com/bartholomej/node-
430
441
  yarn demo
431
442
  ```
432
443
 
433
- ## Development (notes for me)
434
-
435
- ### Publish Stable
436
-
437
- ```shell
438
- yarn release:patch
439
- # yarn release:minor
440
- # yarn release:major
441
- ```
442
-
443
- ### Publish next channel
444
-
445
- 1. Bump version `-beta.0` in `package.json`
446
- 2. `yarn release:beta`
447
-
448
- ## Contribution
444
+ ## 🤝 Contribution
449
445
 
450
446
  I welcome you to customize this according to your needs ;)
451
447
 
@@ -457,7 +453,7 @@ Give a ⭐️ if this project helped you!
457
453
 
458
454
  Or if you are brave enough consider [making a donation](https://github.com/sponsors/bartholomej) for some 🍺 or 🍵 ;)
459
455
 
460
- ## Privacy Policy
456
+ ## 🕵️‍♀️ Privacy Policy
461
457
 
462
458
  I DO NOT STORE ANY DATA. PERIOD.
463
459
 
@@ -465,9 +461,9 @@ I physically can't. I have nowhere to store it. I don't even have a server datab
465
461
 
466
462
  That's why, with node-csfd-api, what happens on your device stays on your device till disappear.
467
463
 
468
- ## License
464
+ ## 📝 License
469
465
 
470
- Copyright &copy; 2020 – 2023 [Lukas Bartak](http://bartweb.cz)
466
+ Copyright &copy; 2020 – 2024 [Lukas Bartak](http://bartweb.cz)
471
467
 
472
468
  Proudly powered by nature 🗻, wind 💨, tea 🍵 and beer 🍺 ;)
473
469
 
@@ -8,4 +8,4 @@ export declare const getUrl: (el: HTMLElement) => string;
8
8
  export declare const getColorRating: (el: HTMLElement) => CSFDColorRating;
9
9
  export declare const getPoster: (el: HTMLElement) => string;
10
10
  export declare const getOrigins: (el: HTMLElement) => string[];
11
- export declare const parsePeople: (el: HTMLElement, type: 'directors' | 'actors') => CSFDCreator[];
11
+ export declare const parsePeople: (el: HTMLElement, type: "directors" | "actors") => CSFDCreator[];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "node-csfd-api",
3
- "version": "2.7.10",
3
+ "version": "2.7.12",
4
4
  "description": "ČSFD API in JavaScript. Amazing NPM library for scrapping csfd.cz :)",
5
5
  "main": "./index.js",
6
6
  "author": "BART! <bart@bartweb.cz>",
@@ -28,7 +28,7 @@
28
28
  },
29
29
  "dependencies": {
30
30
  "cross-fetch": "^4.0.0",
31
- "node-html-parser": "^6.1.12"
31
+ "node-html-parser": "^6.1.13"
32
32
  },
33
33
  "repository": {
34
34
  "url": "git+https://github.com/bartholomej/node-csfd-api.git",
@@ -52,7 +52,7 @@
52
52
  "api"
53
53
  ],
54
54
  "engines": {
55
- "node": ">= 14"
55
+ "node": ">= 18"
56
56
  },
57
57
  "license": "MIT",
58
58
  "lint-staged": {