Skip to content

Angular directive to evaluate expression when an element outside the directive element is clicked

Notifications You must be signed in to change notification settings

superdevofficial/ng-outside-click

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ng-outside-click

Angular directive to evaluate expression when an element outside the directive element is clicked

Usage

<script>
  var app = angular.module('app', ['ngOutsideClick']).run(function($rootScope){
    $rootScope.outsideClick = function(){
      console.log('clicked outside');
    }
  });
</script>

<div outside-click="outsideClick()">
  Clicking anywhere outside this div will trigger the expression in outside-click attribute
</div>

About

Angular directive to evaluate expression when an element outside the directive element is clicked

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%