Provides utility functions for data access, string manipulation, and function debouncing.
Used across multiple modules to simplify common operations.
Methods
(inner) debounce(func, wait) → {function}
Creates a debounced version of a function that delays its execution.
Parameters:
Name | Type | Description |
---|---|---|
func |
function | The function to debounce. |
wait |
number | The delay in milliseconds. |
Returns:
A debounced version of the original function.
- Type
- function
(inner) escapeForHTML(str) → {string}
Escapes backslashes and single quotes in a string for safe HTML/JS injection.
Parameters:
Name | Type | Description |
---|---|---|
str |
string | The string to escape. |
Returns:
The escaped string.
- Type
- string
(inner) getFilmByTitle(title) → {Object}
Retrieves a film object by its title from the film's data.
Parameters:
Name | Type | Description |
---|---|---|
title |
string | The title of the film to retrieve. |
Returns:
The film object containing metadata like title, description, genres, etc.
- Type
- Object
(inner) getSeriesByTitle(title) → {Object}
Retrieves a series object by its title from the series data.
Parameters:
Name | Type | Description |
---|---|---|
title |
string | The title of the series to retrieve. |
Returns:
The series object containing metadata like title, description, seasons, etc.
- Type
- Object