Questions tagged [angularjs-apply]

10 questions
2
votes
1 answer

How to Pass data from Third-Party Library Callback (firebase) to View in AngularJS

I'm working on upload files using angularjs and firebase I'm trying pass parameters from controller to view inside state_changed event It's not working , I can print it on controller but can't use it into view these code that I used // File or…
1
vote
4 answers

JS - Why does angular use an `ng-click="f()"` attribute for handling click events, instead of `$(el).on('click', f)`?

Why does angular use an ng-click="f()" attribute for handling click events, instead of $(el).on('click', f)? I'm asking this because it's generally considered a bad practice to use the html onclick attribute, so why does Angular use this approach?
1
vote
1 answer

Scope variable not getting data object after http service returns

I'm trying to read list of files on a on a server. The HTTP GET method service returns the list of files, but scope variable in controller is not getting updated with the return value. Can you please help me find what is going wrong…
Sharat Chandra
  • 4,434
  • 7
  • 49
  • 66
1
vote
1 answer

AngularJS - wait for data from server and add them correctly to list

I am currently working on an AngularJS project in which I have to get project information, for a specific month and year, from the server and show them to the user. First of all I'm getting a list of Project Id's (projectList), which can be…
Carnifrex
  • 51
  • 1
  • 10
0
votes
2 answers

$scope.$apply() not working - AngularJs

The value of isV(boolean) is not changing despite applying $scope.$apply() after the user enters the correct username and password. $scope.$digest() is also not working app.controller('validateCtrl', function($scope,$location)…
0
votes
1 answer

Is it mandatory to use $scope.$apply for non-angular event

Is it a good practice to always update scope variable(s) using $scope.$apply when the control returns from a non-angular event? I have a use case where same method is used by both angular and non-angular event and I want to avoid code duplication.
comiventor
  • 3,922
  • 5
  • 50
  • 77
0
votes
0 answers

Error: [$rootScope:inprog] $apply already in progress

I just tried to use 'ngTagsInput' in my angular app and the tags in the app are running fine,but sumultaneously its throwing the error in the console.Its not affecting my UI flow but yes errors are logging in the console.Why the cause and solution…
ak1111
  • 107
  • 11
0
votes
2 answers

refresh specific directives in angularjs

I've been pulling my hair out trying every combination imaginable to try to get branches of a tree menu to refresh properly when changes are made to the tree structure. Essentially what I have is a set of recursive nested directives to display the…
Scott
  • 7,983
  • 2
  • 26
  • 41
-1
votes
1 answer

$scope not updating even after using $apply

I am redering a dropdoun list from $scope.saveSearchList in my view below:
-3
votes
2 answers

Where to use $apply instead of using $digest

I would appreciate if anyone can provide any real example which can help me to crack the interview.
ankit paul
  • 81
  • 1
  • 15