diff options
| author | Bartek IwaĆczuk <biwanczuk@gmail.com> | 2021-10-18 19:36:28 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-10-18 19:36:28 +0200 |
| commit | 617eeabe8369d7bfca7951d1cd55ac58ede1f9fb (patch) | |
| tree | 61cfd7b8a5a0230528ed9547c12fcd7183125c6a /cli/tests/testdata/compat/node_fs_promises.js | |
| parent | 5a48d41bddf599b14dd9019ff49821c436ce4542 (diff) | |
feat(unstable): Node CJS and ESM resolvers for compat mode (#12424)
This commit adds CJS and ESM Node resolvers to the "--compat" mode.
The functionality is spread across "cli/compat" module and Node compatibility
layer in "deno_std/node"; this stems from the fact that ES module resolution
can only be implemented in Rust as it needs to directly integrated with
"deno_core"; however "deno_std/node" already provided CJS module resolution.
Currently this resolution is only active when running a files using
"deno run --compat --unstable <filename>", and is not available in other
subcommands, which will be changed in follow up commits.
Diffstat (limited to 'cli/tests/testdata/compat/node_fs_promises.js')
| -rw-r--r-- | cli/tests/testdata/compat/node_fs_promises.js | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/cli/tests/testdata/compat/node_fs_promises.js b/cli/tests/testdata/compat/node_fs_promises.js deleted file mode 100644 index b2174b22b..000000000 --- a/cli/tests/testdata/compat/node_fs_promises.js +++ /dev/null @@ -1,3 +0,0 @@ -import fs from "node:fs/promises"; -const data = await fs.readFile("compat/test.txt", "utf-8"); -console.log(data); |
