nitte93user3232918 nitte93user3232918 - 6 months ago 29
AngularJS Question

AngularJS Data Binding not updating content dynamically

I'm trying to retrieve data from Google books API -

Here's the plnkr link-

I enter the ISBN number(say: 1234) in the search text, and update the bookList with the response items that I received from google.

I'm trying to iterate over these books using
but it's not updating.
I need to click on search twice to see the result in

I'm confused why isn't it updating the content dynamically.

See the plnkr link.

Enter 1234 in the search text and click search, won't update in the html.

Click search again, it updates the html with the last response.


Answer Source

You are using jQuery to make your call, outside angular $digest. You should use $http service instead.

  url: "",
  method: 'GET',
  params: {q:first.inputISBN}

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download