Skip to content

fp-dom/fd-listen

Repository files navigation

fd-listen

Build Status npm version

Handle DOM-events FP-style

Installation

npm install fd-listen --save

Usage

var listen = require('fd-listen');
var select = require('fd-select');

var onClick = listen('click');
var onClickSetClicked = onClick((event) => {
  event.target.innerHTML = 'clicked';
});

onClickSetClicked(select('.link'));

About

Handle events FP-style

Resources

License

Stars

Watchers

Forks

Packages

No packages published