</>PackageGraphPackageGraph

loose-envify

npmv1.4.0

Fast (and loose) selective `process.env` replacer using js-tokens instead of an AST

Not recommended for new projects

No — loose-envify should not be adopted for new projects. Last published 2983 days ago.

  • AAdoption: grade A, Excellent.

    65M downloads per week and 2 known dependents.

  • FMaintenance: grade F, Failing.

    Last published 2983 days ago.

  • AWeight: grade A, Excellent.

    Pulls in 1 transitive package, about 5.7 KB installed (at least — some of the tree is still being crawled).

  • BSupply chain: grade B, Good.

    This package has a single maintainer (bus factor of 1).

  • 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 loose-envify to a project.

1
Direct dependencies

Runtime packages this one declares itself.

1
Total installed

Distinct packages in the full runtime tree, deduplicated the way a package manager would.

5.7 KB
Install size

Unpacked size of this package plus its entire runtime tree.

1
Tree depth

Longest resolved dependency chain below this package.

Part of this dependency tree has not been crawled yet, so these figures are a lower bound rather than a final total.

Compatibility

Node.js
No constraint declared
Module format
CommonJS only
TypeScript
No bundled types
Install scripts
None

Quick start

A usage example from the loose-envify README.

  console.log(`the current env is ${process.env.NODE_ENV}`);

loose-envify vs the alternatives

Packages solving a similar problem in the npm ecosystem, compared on the signals that drive an adoption decision.

PackageWeekly downloadsDependentsLicenseLast release
loose-envifythis page65M2MIT8 years ago
strip-json-comments02MIT1 day ago
getenv07MIT1 day ago
postcss249.3M7MIT1 day ago
path-key244.9M1MIT1 day ago
@jridgewell/gen-mapping163.4M4MIT1 day ago

Dependencies

Declared by loose-envify v1.4.0. Runtime dependencies are installed with the package; dev dependencies are not.

Runtime (1)

js-tokens ^3.0.0 || ^4.0.0

Dev (3)

browserify ^13.1.1envify ^3.4.0tap ^8.0.0

Used by

Popular packages that depend on loose-envify.

Relationship graph

Dependencies (left) and dependents (right) of loose-envify.

invariantfbjsloose-envify
loose-envify dependencies dependents

Frequently installed together

Release history

No releases in the last two years, typically about 167 days apart.

Recent versions of loose-envify
VersionPublishedSizeLicense
1.4.0latest8 years ago5.7 KBMIT
1.3.19 years agoMIT
1.3.010 years agoMIT
1.2.010 years agoMIT
1.1.011 years agoMIT
1.0.011 years agoMIT

Overview

loose-envify is an npm package that fast (and loose) selective `process.env` replacer using js-tokens instead of an AST. It is extremely widely used, with about 65M downloads per week and 2 known dependents in the graph. The latest version is 1.4.0, released under the MIT license.

Who should use it

Teams working in the npm ecosystem who need fast (and loose) selective `process.env` replacer using js-tokens instead of an AST and value a battle-tested, widely-adopted 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

  • Large, well-established user base (65M weekly downloads).
  • 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.

Maintainers

Keywords

Frequently asked questions

Should I use loose-envify?

No — loose-envify should not be adopted for new projects. Last published 2983 days ago.

How do I install loose-envify?

Run `npm install loose-envify` to add loose-envify to your npm project.

How many dependencies does loose-envify have?

loose-envify declares 4 direct dependencies and pulls in 1 packages in total once its runtime tree is resolved totalling about 5.7 KB on disk.

What license is loose-envify released under?

loose-envify is distributed under the MIT license.

How popular is loose-envify?

loose-envify has approximately 65,032,549 downloads per week and 2 known dependent packages.

Is loose-envify still maintained?

The most recent release of loose-envify (v1.4.0) was published 8 years ago.

Does loose-envify run install scripts?

No. loose-envify does not define preinstall, install, or postinstall scripts, so installing it does not execute publisher-supplied code.