Answer the question
In order to leave comments, you need to log in
JS visibility of a callback inside a callback?
I have a code (chrome extension) that i don't understand due to js specifics
chrome.runtime.onMessage.addListener(
function(message, sender, sendResponse)
{
$.ajax({
url: "http://some.site"
,type: "POST"
,data: message
,success: function(data)
{
sendResponse('что-то не работает');
}
});
sendResponse('работает');
}
);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question