Function
| Static Public Summary | ||
| public |
createRecommendations(collectionDoc: CollectionDocJSON): Array<Recommendation> Creates recommendation objects from collection doc ensuring that necessary properties are present |
|
Static Public
public createRecommendations(collectionDoc: CollectionDocJSON): Array<Recommendation> source
import createRecommendations from '@npr/npr-one-sdk/util/recommendation-creator.js'Creates recommendation objects from collection doc ensuring that necessary properties are present
Params:
| Name | Type | Attribute | Description |
| collectionDoc | CollectionDocJSON |
Throw:
if the collectionDoc passed in is not valid |