Return array from function

At a minimum, change this: To this: There are a couple fixes to point out. First, images is not defined in your original function, so assigning property values to it will throw an error. We correct that by changing images to IDs. Second, you want to return an Object, not an Array. An object can … Read more

What does the .subscribe() function do?

The .subscribe() function is similar to the Promise.then(), .catch() and .finally() methods in jQuery, but instead of dealing with promises it deals with Observables. That means it will subscribe itself to the observable of interest (which is getTasks() in your case) and wait until it is successful and then execute the first passed callback function … Read more

How to disable scrolling temporarily?

The scroll event cannot be canceled. But you can do it by canceling these interaction events:Mouse & Touch scroll and Buttons associated with scrolling. [Working demo] UPDATE: fixed Chrome desktop and modern mobile browsers with passive listeners