Skip to content

[BUG] package.json vars documentation seems outdated #61

Open
@a5hk

Description

@a5hk

What / Why

Apparently many package.json vars have been removed since v6 (reference). But docs are still pointing to them here:

You can access these variables in your code with process.env.npm_package_name and process.env.npm_package_version, and so on for other fields.

and here:

Objects are flattened following this format, so if you had {"scripts":{"install":"foo.js"}} in your package.json, then you'd see this in the script:
process.env.npm_package_scripts_install === "foo.js"

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    contentIssues or PRs related to the content of the docs

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions