{"id":13446878,"url":"https://github.com/WebReflection/wrist","last_synced_at":"2025-03-21T16:32:59.409Z","repository":{"id":57399809,"uuid":"80248449","full_name":"WebReflection/wrist","owner":"WebReflection","description":"Minimalistic utility for generic one/two ways data bindings.","archived":false,"fork":false,"pushed_at":"2017-11-07T10:56:00.000Z","size":155,"stargazers_count":52,"open_issues_count":0,"forks_count":7,"subscribers_count":7,"default_branch":"master","last_synced_at":"2025-03-19T09:03:20.200Z","etag":null,"topics":["bindings","changes","dom","js","observe","property","two-way","watch"],"latest_commit_sha":null,"homepage":"https://medium.com/@WebReflection/js-dom-data-bindings-in-2017-1545f38cfdc8#.yy4lk656m","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/WebReflection.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-01-27T21:40:50.000Z","updated_at":"2024-09-02T12:58:10.000Z","dependencies_parsed_at":"2022-09-26T17:01:16.995Z","dependency_job_id":null,"html_url":"https://github.com/WebReflection/wrist","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WebReflection%2Fwrist","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WebReflection%2Fwrist/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WebReflection%2Fwrist/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/WebReflection%2Fwrist/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/WebReflection","download_url":"https://codeload.github.com/WebReflection/wrist/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244829651,"owners_count":20517350,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bindings","changes","dom","js","observe","property","two-way","watch"],"created_at":"2024-07-31T05:01:02.158Z","updated_at":"2025-03-21T16:32:59.126Z","avatar_url":"https://github.com/WebReflection.png","language":"HTML","readme":"# wrist [![Build Status](https://travis-ci.org/WebReflection/wrist.svg?branch=master)](https://travis-ci.org/WebReflection/wrist) [![Coverage Status](https://coveralls.io/repos/github/WebReflection/wrist/badge.svg?branch=master)](https://coveralls.io/github/WebReflection/wrist?branch=master)\n\nAn easy way to bind or react to properties change.\n\nIt also works with `input` elements and their `value`, `checked`, or `disabled` too.\n\n```js\nconst watcher = wrist.watch(\n  // generic Object or DOM element\n  generic,\n  // the property name to watch\n  'propertyName',\n  // the callback that will trigger\n  // only when property value changes\n  function cb(propName, oldVal, newVal) {\n    this === generic; // true\n    propName;         // \"propertyName\"\n  }\n);\n\n// to drop a watcher\nwatcher.unwatch();\n\n// or via unwatch and same watch signature\nwrist.unwatch(generic, 'propName', cb);\n```\n\nEach property can have more than one callback registered.\n\nDual bindings do not interfere with each other.\n\n[Live test page](https://webreflection.github.io/wrist/examples/).\n\n[Related post](https://medium.com/@WebReflection/js-dom-data-bindings-in-2017-1545f38cfdc8#.s69edll9v).\n\n### Compatibility\n\nIE9 Desktop, as well as IE9 Mobile in WP7 are the IE baseline.\n\nEvery Desktop browser works, and in Firefox case, even Firefox OS 1 does.\n\nHowever, old stock browsers found in Android 2~4, WebOS, iOS 5 (OK, not stock but same bug) have a WebKit bug that won't make properties like `input.value` be configurable.\n\nIn these cases, other regular, non special attributes, would work, but that's kinda missing the point ow wrist.\n\nIf you need to support jurassic mobile browsers, please look elsewhere, apologies.\n\n- - -\n\n(C) 2017 Andrea Giammarchi - MIT Style License\n","funding_links":[],"categories":["HTML"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FWebReflection%2Fwrist","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FWebReflection%2Fwrist","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FWebReflection%2Fwrist/lists"}