Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/piotrts/monsato
A lightweight MutationObserver wrapper for ClojureScript
https://github.com/piotrts/monsato
clojure clojurescript mutationobserver
Last synced: 25 days ago
JSON representation
A lightweight MutationObserver wrapper for ClojureScript
- Host: GitHub
- URL: https://github.com/piotrts/monsato
- Owner: piotrts
- License: epl-1.0
- Created: 2016-11-01T21:32:38.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2017-06-24T21:39:29.000Z (over 7 years ago)
- Last Synced: 2024-09-28T17:40:53.463Z (about 1 month ago)
- Topics: clojure, clojurescript, mutationobserver
- Language: Clojure
- Size: 13.7 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Monsato
**A lightweight MutationObserver wrapper for ClojureScript**
Work in progress. Current version: 0.1.0.
## Installation
Add the following dependency to your `project.clj`:
```clojure
[monsato "0.1.1"]
```## Example usage
```clojure
(require '[monsato.core :as m]
'[goog.dom :as gdom])(def obs (m/observer))
(m/observe obs (gdom/getElement "watchme") #(prn %))
```
`observe` also accepts a core.async channel as its last parameter:```clojure
(let [obs (m/observer)
ch (chan)]
(go-loop []
(prn (