Elestia Open Source Ratings
6.3

Needle DI

Reasonable, with limits. 3rd of 7 dependency injection.

Needle DI is a small, type-safe DI container. It uses native ECMAScript decorators and needs neither reflect-metadata nor experimentalDecorators. Its API is clean and modern and it keeps getting small releases. Its user base is still tiny, and almost no one outside the project has validated it, so it is a reasonable pick for small, modern TypeScript codebases but not yet a safe default.

Best for: TypeScript or JavaScript projects that want Angular-style inject() with native decorators and no reflect-metadata, and that accept a young, single-maintainer library.

WebsiteGitHubnpm

Scores

Overall6.3

How strongly do we recommend it for a new project today?

Claude Opus 5.5: 5.5, likely 4.5 to 6.5

Technically it is one of the most modern options. It uses native decorators, needs no reflect-metadata, has strong types and keeps getting releases, while InversifyJS, TSyringe and TypeDI have seen almost no commits. Its tiny user base, missing outside validation and single maintainer make it riskier than Awilix, which is active and widely used. It is a reasonable choice with real limits.

  • peers commitsLastYear: Awilix had 68 commits; InversifyJS, TSyringe and TypeDI had 0 or 1.
  • github.com/needle-di/needle-di/releases: Active releases through 2026.
  • github stars: 142 stars; low adoption.

GPT-6.2 Sol: 7.0, likely 5.8 to 8.1

Needle DI is a strong pick for new ESM projects that want typed injection without reflection or extra runtime dependencies. Awilix is a better default for Node.js services that need explicit lifetimes and automatic resource cleanup. Needle DI's recent fixes and growing use support choosing it today, with single-maintainer release ownership and unsettled child-container behavior leaving some uncertainty.

Needed by many4.3

How many developers need a tool for this job?

Claude Opus 5.5: 4.5, likely 3.5 to 5.5

Many JS/TS projects never need a DI container, and backend or large-app TypeScript teams are its main users. Needle DI works with any framework and runtime, so it covers the whole category. The category itself is a clear but medium-sized niche.

  • needle-di.io: Runs in browsers and Node.js, standalone, ESM.
  • JS DI usage patterns: Many JS projects wire dependencies by hand or through framework DI such as Angular's or NestJS's.

GPT-6.2 Sol: 4.1, likely 2.9 to 5.4

A standalone container helps when an app has enough services that manual wiring becomes cumbersome. Needle DI works across Node.js, Deno, and browsers, but its ESM-only design and the built-in containers in frameworks such as NestJS narrow its audience. The survey gives framework context, while the share of developers who need a standalone container remains an estimate.

Helps a lot6.9

How well does it do the job for those who need it?

Claude Opus 5.5: 6.5, likely 5.5 to 7.5

The design is modern: native decorators, an inject() function and full type inference, with no reflect-metadata. Async, child containers, multi, lazy and optional injection are all documented. The 2026 releases fixed several concurrency bugs in async resolution, which shows that edge cases are still being found. There is no page on scopes or testing, and the small community means fewer known patterns than Awilix or Inversify have.

GPT-6.2 Sol: 7.2, likely 6.0 to 8.3

Version 1.2.1 offers typed tokens, lazy and async providers, and a documented API with examples for coding agents. Async code needs explicit container access once it leaves the synchronous injection context, and child containers can duplicate auto-bound singletons. Awilix has richer lifetime and cleanup controls. Needle DI's relative performance and the reliability of AI-generated code remain lightly tested in public.

Holds up over time5.6

Will it still be a good choice in two years?

Claude Opus 5.5: 5.0, likely 3.5 to 6.5

It had 5 releases and 20 commits in the last year, and 1.0 shipped in April 2025 with no breaking changes since. Only 19 issues have ever been closed, and 5 are open, so the issue load is light. One person, with no sponsor, appears to do most of the work, which makes it a risk to depend on. The ecosystem is moving towards native decorators, and that works in its favour.

  • github commitsLastYear / releasesLastYear: 20 commits, 5 releases in the last year.
  • github.com/needle-di/needle-di/releases: Steady releases from v1.0.0 (April 2025) to v1.2.1 (September 2026), none marked breaking.
  • github contributors: 8 contributors; the copyright names one author.

GPT-6.2 Sol: 6.2, likely 4.8 to 7.5

Needle DI shipped five releases and made 20 commits over the past year, with recent fixes for async resolution and a TypeScript regression. The public release history shows one releaser, and Replit's sponsorship request has no public funding confirmation. A proposed change to child-container defaults could require a major upgrade, and Awilix has a stronger recent maintenance record.

Used widely3.1

How many use it, and is that growing?

Claude Opus 5.5: 2.5, likely 1.5 to 3.5

It had about 105k downloads in the last 4 weeks, up from about 9k a year ago. That ratio of about 11.7 is far above the 4.1 median, so it is gaining ground, but from a very small base. With 142 stars, no dependents count and no posts, it reaches a small fraction of what InversifyJS, TSyringe or Awilix reach. Part of the downloads may come from a few packages that depend on it.

  • npm downloadsLast4Weeks / downloadsSame4WeeksYearAgo: 104,814 vs 8,978, a ratio of about 11.7 against a median of 4.1.
  • github stars: 142 stars, against thousands for most peers.
  • bluesky posts / hackerNews stories: No posts and no stories.

GPT-6.2 Sol: 3.6, likely 2.0 to 5.3

Four-week npm downloads rose from 8,978 to 104,814, or 11.7 times the prior year, well above the catalog median of 4.1. The install base is still small next to Awilix and InversifyJS, and some installs come through packages such as ZeltJS. The missing ecosyste.ms count and limited public attention leave the number of direct adopters uncertain.

  • npm downloadsLast4Weeks and downloadsSame4WeeksYearAgo: 104,814 versus 8,978 downloads.
  • medianDownloadsRatio: Needle DI's 11.7 times growth exceeds the 4.1 baseline.
  • peers: Above Brandi in downloads and far below Awilix and InversifyJS.
  • github stars, dependents, hackerNews, and bluesky: 142 stars, no indexed dependent count, and no matched posts or stories.
  • zeltjs.com/ja/docs/dependency-injection: ZeltJS embeds Needle DI, creating installs from indirect users.
Vouched for3.9

Who stands behind it being good?

Claude Opus 5.5: 2.0, likely 1.0 to 3.5

We found no named production users, no survey mentions, no independent comparisons and no Hacker News or Bluesky discussion. Web searches for the name mostly return Uber's Swift Needle or other packages with the same name. Its quality rests on its own docs alone.

  • github.com/needle-di/needle-di: The 'Used by' section names no notable users.
  • hackerNews stories / bluesky posts: Zero for both.
  • dependents: ecosyste.ms has no count.

GPT-6.2 Sol: 5.8, likely 4.3 to 7.0

Replit publicly reported depending on Needle DI, and ZeltJS uses it for its built-in container. An independent React starter documents request scoping and test overrides in practice. Public evidence about the scale of production use, comparative performance, and developer satisfaction remains limited.

Safe7.7

How safe is it to depend on?

Claude Opus 5.5: 7.5, likely 6.0 to 8.5

It has zero runtime dependencies, no known advisories and an MIT licence. Releases run through release-please. There is no Scorecard data, and one maintainer controls publishing, which keeps it below the top of the scale.

  • npm dependencies: 0 dependencies.
  • advisories total: No advisories.
  • scorecard: No Scorecard data.
  • npm license: MIT.

GPT-6.2 Sol: 7.8, likely 6.6 to 8.9

The MIT-licensed package has zero runtime dependencies and no recorded OSV advisories. GitHub Actions publishes the package, and JSR reports a signed build. A single visible releaser, the lack of a published security policy, and the missing OpenSSF Scorecard limit confidence in the release and response process.

Good

  • Uses native ECMAScript decorators and inject(), so it needs no reflect-metadata and no experimentalDecorators or emitDecoratorMetadata.
  • Has zero runtime dependencies, a small bundle and injection tokens that can be tree-shaken.
  • Covers the advanced cases: async factories, child containers, multi-injection, lazy and optional injection, and unbind.
  • Infers types fully from tokens, and publishes llms.txt docs that help AI agents write correct code.

Bad

  • One maintainer does most of the work, and no company sponsors it.
  • Its user base is tiny next to InversifyJS, TSyringe or Awilix, and there are few community answers or examples.
  • We found no independent reviews, benchmarks or named production users.
  • Its docs have no page on scopes or testing, and recent releases still fix edge cases in async resolution.

The numbers

npm downloads, 4 weeks
105k ×12 in a year
GitHub stars
142
Commits, 12 months
20
npm version
1.2.1 Sept 2026
Versions, 12 months
5
Advisories, 24 months
0 of 0 ever
OpenSSF Scorecard
None
Licence
MIT

Read on 21 November 2026 from GitHub (needle-di/needle-di), npm (@needle-di/core), OSV and the OpenSSF Scorecard.

Dependency injection

  1. 7.5Awilix
  2. 7.4InversifyJS
  3. 6.3Needle DI
  4. 5.2injection-js
  5. 5.2TSyringe
  6. 4.7Brandi
  7. 3.1TypeDI
Compare all 7 on six scores