@zambezi/d3-rebind

3.5.17 • Public • Published

d3-rebind

Copies a variable number of methods from source to target.

This is a verbatim extraction from d3.v3.5.17 source code, available here.

Installing

If you use NPM, npm install @zambezi/d3-rebind. Otherwise, download the latest release.

API Reference

# rebind(target, source, names…)

Copies the methods with the specified names from source to target, and returns target. Calling one of the named methods on the target object invokes the same-named method on the source object, passing any arguments passed to the target method, and using the source object as the this context. If the source method returns the source object, the target method returns the target object (“setter” method); otherwise, the target method returns the return value of the source method (“getter” mode). The rebind operator allows inherited methods (mix-ins) to be rebound to a subclass on a different object.

Readme

Keywords

Package Sidebar

Install

npm i @zambezi/d3-rebind

Weekly Downloads

1

Version

3.5.17

License

MIT

Last publish

Collaborators

  • gabriel.montagne
  • robert.gorecki.at.natwest.com
  • mstade