Advertisement
Guest User

Untitled

a guest
Jun 27th, 2019
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. this.loading = true; // init as true just before $http call
  2. $http({
  3. method: 'POST',
  4. url: "URL",
  5. data: "myParam"
  6. }).then(function successCallback(response) {
  7. // after getting response set the loading variable to false
  8. this.loading = false;
  9. });
  10.  
  11. <div ng-if="!ctrl.loading>
  12. //your original html content here
  13. </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement