Skip to content

Module Not Exported for NodeJS #4

Description

@PowerOfM

The file micro-enum.js has no module.exports definition. Since this file is imported by index.js, the result is an empty object.

Test script:

const Enum = require('simple-enum')

var MyEnum = Enum('A', 'B', 'C')

When running that script:
TypeError: Enum is not a function

The REPL shows that Enum is an empty object.

Activity

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions