Skip to content

Commit

Permalink
docs(node api): note TLA caveat
Browse files Browse the repository at this point in the history
  • Loading branch information
privatenumber committed May 11, 2024
1 parent 0e7f34e commit dc661ab
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions docs/node/tsx-require.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ Use this function for importing TypeScript files in CommonJS mode without adding

Note, the current file path must be passed in as the second argument to resolve the import context.

::: warning Caveat
`import()` & asynchronous `require()` calls in the loaded files are not enhanced.
::: warning Caveats
- `import()` & asynchronous `require()` calls in the loaded files are not enhanced.
- Because it compiles ESM syntax to run in CommonJS mode, top-level await is not supported
:::

## CommonJS usage
Expand Down

0 comments on commit dc661ab

Please sign in to comment.