{"id":15658331,"url":"https://github.com/gvergnaud/rx-ease","last_synced_at":"2026-03-06T15:32:27.950Z","repository":{"id":34159503,"uuid":"133255906","full_name":"gvergnaud/rx-ease","owner":"gvergnaud","description":"Spring animation operator for rxjs 🦚✨","archived":false,"fork":false,"pushed_at":"2023-01-04T04:04:21.000Z","size":1489,"stargazers_count":21,"open_issues_count":3,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-09-28T11:54:30.970Z","etag":null,"topics":["animation","damping","interpolation","observable","operator","reactive","rxjs","spring","stiffness","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gvergnaud.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-05-13T16:42:22.000Z","updated_at":"2024-10-08T17:13:07.000Z","dependencies_parsed_at":"2023-01-15T04:59:45.586Z","dependency_job_id":null,"html_url":"https://github.com/gvergnaud/rx-ease","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/gvergnaud/rx-ease","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gvergnaud%2Frx-ease","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gvergnaud%2Frx-ease/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gvergnaud%2Frx-ease/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gvergnaud%2Frx-ease/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gvergnaud","download_url":"https://codeload.github.com/gvergnaud/rx-ease/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gvergnaud%2Frx-ease/sbom","scorecard":{"id":450601,"data":{"date":"2025-08-11","repo":{"name":"github.com/gvergnaud/rx-ease","commit":"5797b9704a7bc8e21fe55f9a773d810f2dc075a6"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":1.3,"checks":[{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Code-Review","score":0,"reason":"Found 0/6 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 24 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"26 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-v88g-cgmw-v5xw","Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-cwfw-4gq5-mrqx","Warn: Project is vulnerable to: GHSA-g95f-p29q-9xw4","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-w573-4hg7-7wgq","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-896r-f27r-55mw","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-4xcv-9jjx-gfj3","Warn: Project is vulnerable to: GHSA-7wpw-2hjm-89gp","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-5fw9-fq32-wv5p","Warn: Project is vulnerable to: GHSA-hrpp-h998-j3pp","Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q","Warn: Project is vulnerable to: GHSA-p9pc-299p-vxgp"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-19T08:07:03.428Z","repository_id":34159503,"created_at":"2025-08-19T08:07:03.428Z","updated_at":"2025-08-19T08:07:03.428Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30183473,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-06T14:42:24.748Z","status":"ssl_error","status_checked_at":"2026-03-06T14:42:14.925Z","response_time":250,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["animation","damping","interpolation","observable","operator","reactive","rxjs","spring","stiffness","typescript"],"created_at":"2024-10-03T13:11:59.504Z","updated_at":"2026-03-06T15:32:27.925Z","avatar_url":"https://github.com/gvergnaud.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# rx-ease\n\nAn animation operator for RxJs Observables!\n\n- **Physic based**. The animation seemlessly interupts itself if a new value is emitted before it completes.\n- **Performant**, emits on **requestAnimationFrame** at 60fps.\n- **Typescript** first class support.\n- **Versatile**, Works with any kind of data structures (Object, arrays, single values).\n\n## Install\n\n```\nnpm install rxjs rx-ease\n```\n\n## The gist\n\n#### Interpolate between emitted numbers\n\nYou can simply use the `ease` operator in an observable pipeline. You need to configure the ease operator with two numbers: a **stiffness** value and a **damping** value. See [the presets sections](https://github.com/gvergnaud/rx-ease#presets) bellow for example of configurations.\n\n\n```js\nimport { interval } from 'rxjs'\nimport { take, map, startWith } from 'rxjs/operators'\nimport ease from 'rx-ease'\n\nconst draw = x =\u003e\n  Array(Math.floor(x))\n    .fill('#')\n    .join('')\n\nconst progress$ = interval(1000).pipe(\n  startWith(0),\n  map(i =\u003e * 100),\n  ease(120, 18),\n  map(draw)\n)\n\nprogress$.subscribe(progress =\u003e console.log(progress))\n// will log =\u003e\n// #\n// ####\n// ########\n// #############\n// #################\n// ######################\n// ##########################\n// ##############################\n// ##################################\n// ######################################\n// #########################################\n// ############################################\n// ##############################################\n// ################################################\n// ##################################################\n// ####################################################\n// #####################################################\n// ######################################################\n// #######################################################\n// ########################################################\n// #########################################################\n// ##########################################################\n// ##########################################################\n// ##########################################################\n// ##########################################################\n```\n\n#### Interpolate several properties of an object\n\nIf your Observable emits an object instead of a single number, you can use the `ease` operator to interpolate the values of one or several properties of this object. Just pass to `ease` an object of the same shape as the observed value with a config for each property you want to ease.\n\n```js\nimport { fromEvent } from 'rxjs'\nimport { map } from 'rxjs/operators'\nimport ease from 'rx-ease'\n\nconst circle = document.querySelector('.circle')\n\nconst position$ = fromEvent(document, 'click').pipe(\n  map(e =\u003e ({ x: e.clientX, y: e.clientY })),\n  ease({\n    x: [120, 18],\n    y: [120, 18]\n  })\n)\n\nposition$.subscribe(({ x, y }) =\u003e {\n  circle.style.transform = `translate(${x}px, ${y}px)`\n})\n```\n\n## Api\n\nSimilarly to [react-motion](https://github.com/chenglou/react-motion), rx-ease is a **spring animation** operator. To configure the animation you need to pass a stiffness and a damping value in an array like `[stiffness, damping]` (for example `[120, 18]`).\n\n\n\n#### Easing a single value\n\n##### signature\n\n```ts\ntype Config = [number, number]\nease: (config: Config) =\u003e (stream: Observable\u003cnumber\u003e) =\u003e Observable\u003cnumber\u003e\n```\n\n##### example\n\n```js\nimport { interval } from 'rxjs'\nimport ease from 'rx-ease'\n\nconst easedInterval$ = interval(1000).pipe(\n  map(x =\u003e x * 100),\n  ease([170, 26])\n)\n```\n\n\n#### Easing values of an array\n\n##### signature\n\n```ts\nease: (config: Config[]) =\u003e (stream: Observable\u003cnumber[]\u003e) =\u003e Observable\u003cnumber[]\u003e\n```\n\n##### example\n\n```js\nimport { fromEvent } from 'rxjs'\nimport ease from 'rx-ease'\n\nconst easedMousePosition$ = fromEvent(window, 'mousemove').pipe(\n  map(e =\u003e [e.clientX, e.clientY]),\n  ease([\n    [170, 26],\n    [170, 26],\n  ])\n)\n```\n\n#### Easing properties of an object\n\n##### signature\n\n```ts\nease: (config: Record\u003cK, Config\u003e) =\u003e (stream: Observable\u003cRecord\u003cK, Config\u003e\u003e) =\u003e Observable\u003cRecord\u003cK, Config\u003e\u003e\n```\n\n##### example\n\n```js\nimport { fromEvent } from 'rxjs'\nimport ease from 'rx-ease'\n\nconst easedMousePosition$ = fromEvent(window, 'mousemove').pipe(\n  map(e =\u003e ({\n    x: e.clientX,\n    y: e.clientY\n  }),\n  ease({\n    x: [170, 26],\n    y: [170, 26],\n  })\n)\n```\n\n#### presets\n- **noWobble**: equivalent to passing `[170, 26]`\n- **gentle**: equivalent to passing `[120, 14]`\n- **wobbly**: equivalent to passing `[180, 12]`\n- **stiff**: equivalent to passing `[210, 20]`\n\n```js\nimport ease, { presets } from 'rx-ease'\n\ninterval(1000).pipe(\n  map(x =\u003e x * 100),\n  ease(...presets.stiff)\n)\n```\n\n## Credits\n\nThis was heavily inspired by @chenglou's [react-motion](https://github.com/chenglou/react-motion).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgvergnaud%2Frx-ease","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgvergnaud%2Frx-ease","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgvergnaud%2Frx-ease/lists"}