Skip to content

require.extensions is deprecated #1302

Closed

Description

@NickHeiner

This project works via require.extensions: docs, code. However, the Node docs say that require.extensions is deprecated.

image

Does this project have a path forward towards using a non-deprecated approach?

Activity

  1. cspotcode commented on May 3, 2021

    @cspotcode
    Collaborator

    Correct, that has been the case for an extremely long time and node does not offer alternatives. Unless you're referring to ESM loaders, in which case yes, we have one of those. See #1007

    Although it is deprecated, experience shows that it is also stable, and has been that way for years. If you're concerned that this deprecation is a risk, don't worry. All the evidence suggests that this API surface is not going anywhere.

    If you're curious about this topic, you may want to check node's issue tracker, since it's possible that users have requested a non-deprecated API surface to replace this one. The node folks might have some thoughts on why they opted to keep this stable, deprecated API surface instead of creating a replacement. You can also dig deeper into our issue tracker since this has already been asked here.

  2. NickHeiner commented on May 4, 2021

    @NickHeiner
    Author

    That's fair. Thanks for the thoughtful analysis!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions