Module-documentation

version 1.0.0
module: event-dom
maintanance: Marco Asbreuk
home
all modules

DOM-events

DOM-events can be listened by without an emitterName. By using the `filter`-argument you specify which node to listen to. Because the filter (selector) is a String, we can pass it as 3rd parameter.

Click on the Show popup to to show a pop-up.

Code-example:

<body>
    <button id="buttongo" class="pure-button pure-button-primary pure-button-bordered">Show popup</button>
</body>
<script src="itsabuild-min.js"></script>
<script>
    var showMsg = function(e) {
        alert('Button was clicked');
        console.log(e);
    };

    ITSA.Event.after('tap', showMsg, '#buttongo');
</script>
API Docs