@newskit-render/standalone-components 0.18.0 → 0.18.2-alpha.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.
Files changed (2) hide show
  1. package/README.md +12 -1
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -16,9 +16,20 @@ For npm:
16
16
 
17
17
  ## Components
18
18
 
19
- 1. Article recommendations: this component provides two main facilities:
19
+ 1. Article recommendations
20
+
21
+ - Endpoint `/api/recommendations` is used in the `core` package which returns a list on recommendations articles.
22
+
23
+ - Endpoint accepts the following params
24
+ - `articleId`
25
+ - `userId`
26
+
27
+ - Endpoint used in the following files in the `core` package
28
+ - `packages/core/pages/[section]/[articleId]/[articleSlug].tsx`
29
+ - `packages/core/pages/[section]/[articleId]/relatedArticles.tsx`
20
30
 
21
31
  - recommendationsProvider: Provider function that accepts `articleId`, `publisher` and `userId`. The function will return an array of recommended articles.
32
+
22
33
  - ArticleRecommendation: a component that accepts `article` and `size`, where
23
34
 
24
35
  - `article` is an object with the following properties:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@newskit-render/standalone-components",
3
- "version": "0.18.0",
3
+ "version": "0.18.2-alpha.0",
4
4
  "description": "Newskit Render Standalone Components",
5
5
  "author": "",
6
6
  "license": "UNLICENSED",
@@ -77,7 +77,7 @@
77
77
  },
78
78
  "dependencies": {
79
79
  "@apollo/client": "3.4.16",
80
- "@newskit-render/api": "^0.32.0",
80
+ "@newskit-render/api": "^0.32.1-alpha.0",
81
81
  "graphql": "15.6.0",
82
82
  "lodash.merge": "4.6.2"
83
83
  },