Module

services/search

Service to handle the search methods

Methods

# async inner getTrends(params, segmentationValueopt) → {Promise.<Array.<Object>>}

Get last publised movies and shows to represent as trends

Parameters:
Name Type Attributes Description
params Object

Params object

amount Number <optional>

Items per type, by default is 5

segmentationValue string <optional>

optional segment to get a different value based on config

Results

Promise.<Array.<Object>>

# async inner search(params) → {Promise.<Array.<Object>>}

Search for Movies and Shows

Parameters:
Name Type Attributes Description
params Object

Params object

keyword String

Keyword to search

amount Number <optional>

Items per type

segmentationValue string <optional>

optional segment to get a different value based on config

Results

Promise.<Array.<Object>>

# inner sort(a, b) → {Number}

Sort two elements to determine the best order

Parameters:
Name Type Description
a Object

Array element

b Object

Array element

Sort result

Number