function-bind
npmv1.1.2Implementation of Function.prototype.bind
Adopt with care
function-bind is usable, with caveats. Last published 1063 days ago.
- ?Adoption: grade ?, Not reported by this registry.
No download data reported for this package yet.
- DMaintenance: grade D, Poor — a real concern.
Last published 1063 days ago.
- AWeight: grade A, Excellent.
Zero runtime dependencies, about 31 KB installed.
- ASupply chain: grade A, Excellent.
No install scripts, 2 maintainers, and a contained dependency surface.
- ALicense: grade A, Excellent.
MIT — permissive, with no copyleft found in the dependency tree.
Grades are computed deterministically from registry metadata collected by PackageGraph — downloads, dependents, publish dates, the resolved dependency tree, maintainer count, and declared licenses. No third-party scores are used.
Install cost
What you actually take on by adding function-bind to a project.
Runtime packages this one declares itself.
Distinct packages in the full runtime tree, deduplicated the way a package manager would.
Unpacked size of this package plus its entire runtime tree.
Longest resolved dependency chain below this package.
Compatibility
- Node.js
- No constraint declared
- Module format
- CommonJS only
- TypeScript
- No bundled types
- Install scripts
- None
Quick start
A usage example from the function-bind README.
Function.prototype.bind = require("function-bind")function-bind vs the alternatives
Packages solving a similar problem in the npm ecosystem, compared on the signals that drive an adoption decision.
| Package | Weekly downloads | Dependents | License | Last release |
|---|---|---|---|---|
| function-bindthis page | 0 | 5 | MIT | 2 years ago |
| call-bind | 80.7M | 5 | MIT | 1 day ago |
| functions-have-names | 0 | 5 | MIT | 1 day ago |
| call-bound | 0 | 7 | MIT | 1 day ago |
| callsites | 136.7M | 1 | MIT | 1 day ago |
| once | 109.6M | 1 | ISC | 1 day ago |
Dependencies
Declared by function-bind v1.1.2. Runtime dependencies are installed with the package; dev dependencies are not.
Dev (9)
Used by
Popular packages that depend on function-bind.
Simplified HTTP request client.
A robust, ES3 compatible, "has own property" predicate.
Get and robustly cache all JS language-level intrinsics at first require time
Set a function's length property
Helper functions around Function call/apply/bind, for use in `call-bind`
Relationship graph
Dependencies (left) and dependents (right) of function-bind.
Frequently installed together
An AST-based pattern checker for JavaScript.
string representations of objects in node and the browser
A simple cache for a few of the JS Error constructors.
`Object.getOwnPropertyDescriptor`, but accounts for IE's broken implementation.
RFC9562 UUIDs
The ultimate javascript content-type utility.
ES Math-related intrinsics and helpers, robustly cached.
`Object.defineProperty`, but not IE 8's broken one.
Robustly `.call.bind()` a function
Port of jQuery.extend for node.js and the browser
HTTP proxy tunneling agent. Formerly part of mikeal/request, now a standalone module.
Like JSON.stringify, but doesn't blow up on circular refs.
Release history
No releases in the last two years, typically about 497 days apart.
| Version | Published | Size | License |
|---|---|---|---|
| 1.1.2latest | 2 years ago | 31 KB | MIT |
| 1.1.1 | 9 years ago | — | MIT |
| 1.1.0 | 10 years ago | — | MIT |
| 1.0.2 | 12 years ago | — | MIT |
| 1.0.0 | 12 years ago | — | MIT |
| 0.1.0 | 13 years ago | — | MIT |
Overview
function-bind is an npm package that implementation of Function.prototype.bind. It has 5 known dependents in the graph. The latest version is 1.1.2, released under the MIT license.
Who should use it
Teams working in the npm ecosystem who need implementation of Function.prototype.bind and value a focused solution.
When not to use it
Consider an alternative if you need to have first-class TypeScript types out of the box, or if a more actively-maintained option better fits your npm stack.
Pros
- Clear open-source license (MIT).
Cons
- No bundled TypeScript types (may require a separate @types package).
Auto-generated from collected registry metadata. No external claims are inferred.
Funding
Frequently asked questions
Should I use function-bind?
function-bind is usable, with caveats. Last published 1063 days ago.
How do I install function-bind?
Run `npm install function-bind` to add function-bind to your npm project.
What license is function-bind released under?
function-bind is distributed under the MIT license.
How popular is function-bind?
npm does not publish download counts. Within PackageGraph's crawl, 5 known packages depend on function-bind.
Is function-bind still maintained?
The most recent release of function-bind (v1.1.2) was published 2 years ago.
Does function-bind run install scripts?
No. function-bind does not define preinstall, install, or postinstall scripts, so installing it does not execute publisher-supplied code.