@micosmo/core
Version:
Core Javascript language extensions
33 lines (19 loc) • 1.43 kB
Markdown
# @micosmo/core/bind
Contains an alternate *bind* function that will return the same bound function instance for the same inputs.
## API
### IMPORTING
```javascript
const { bind } = require('@micosmo/core/bind');
```
### EXPORTS
Function | Description
-------- | -----------
bind(f, o) | Return a bound function of *f* for *o*. Returns the same bound function for the same *f* and *o*.
## HISTORY
### Version - 0.1.2
* Fixed bind issue where bound functions were being held beyond the life of the associated object. In many cases objects could not be garbage collected.
## LICENSE
ISC - Internet Systems Consortium
Copyright 2019 Micosmo ([www.micosmo.com](http://www.micosmo.com))
Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.