Skip to content

module: NODE_PRIORITIZED_PATH didn't precede relative node_modules #551

@legendecas

Description

@legendecas
  • Version: v0.11.x
  • Platform: all
  • Subsystem: module

Suppose we have following structure:

-- /
 |- /vendor
 |  |- /lru-cache
 |
 |- /workspace
    |- /node_modules
    |  |- /lru-cache
    |
    | index.js

While we run index.js in directory /workspace with NODE_PRIORITIZED_PATH set to /vendor, /workspace/node_modules/lru-cache would still be used but not /vendor/lru-cache. This behavior is not as aligned with document, in which NODE_PRIORITIZED_PATH is preceding node_modules folder under current working directory.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions