Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

5
  • 1
    bun worked perfectly for me Commented Oct 31, 2023 at 18:23
  • 2
    @DzmitryLahoda sure but bun has many significant differences to node.js Commented Nov 9, 2023 at 15:45
  • Solution 2 works with .ts > .js as long as you have "type": "module", in your package.json. Or use the .mts extension to get a .mjs file without it! Commented May 27, 2024 at 10:44
  • 1
    This should be the correct answer, solution 2 works! Commented Dec 18, 2024 at 12:31
  • 1
    Thanks @FelipeMorais! I feel the same way - the other answer isn't really answering the question. Maybe write that as a comment on the question, that way the original question asker will see it! Commented Dec 18, 2024 at 15:49