Data loss at Ajax subscribe

Issue

This Content is from Stack Overflow. Question asked by Lutek

I want to fetch video data from vimeo and assign it to new object with it’s own interface.

videoData object
getVideoData method

The problem is with the videoData object. When i console.log it and it’s value (eg.: videoData.name) inside subscribe – everything is fine. But when i try to console.log it after subscribe the object and it’s values exist but when i try to get the value (eg.: videoData.name) it’s an empty string.

Does anybody has an idea how can i get these values?



Solution

This question is not yet answered, be the first one who answer using the comment. Later the confirmed answer will be published as the solution.

This Question and Answer are collected from stackoverflow and tested by JTuto community, is licensed under the terms of CC BY-SA 2.5. - CC BY-SA 3.0. - CC BY-SA 4.0.

people found this article helpful. What about you?