freeqer cyber_fear
freeqer cyber_fear

Reputation: 11

Is AngularJS $scope always bad and impact performance so hard?

I'm doing application in angularjs. But at work my team leader whant as to use pure javascript and or jqlite as much as we can. He whant as to avoid $scope, and make all DOM manipulation by traditional way as getElementsByClassName and change it with .html() function. Is this approach good? Is $scope that bad and impact performance? And also he wanted as to delete bower and use only npm. His argument was, not to use two managers...? Is he right?

Upvotes: 1

Views: 550

Answers (1)

topheman
topheman

Reputation: 7912

1) In Angular 1, it's not using $scope that you should avoid, but it's adding too much watchers. If you're using Angular 1, you should take advantage of the data-binding it offers.

Though, if you find yourself with a directive loading a table containing 50K lines, you might want to do some optimizations ...

2) About getting rid of bower: I agree with him (npm already does what bower does, why have two different package managers ?)

Upvotes: 2

Related Questions