1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-22 15:06:54 -05:00
denoland-deno/ext/node
Marvin Hagemeister 8c051dbd1a
fix(ext/node): add missing _preloadModules hook (#18447)
This internal node hook is used by libraries such as `ts-node` when used
as a require hook `node -r ts-node/register`. That combination is often
used with test frameworks like `mocha` or `jasmine`.

We had a reference to `Module._preloadModules` in our code, but the
implementation was missing. While fixing this I also noticed that the
`fakeParent` module that we create internally always threw because of
the `pathDirname` check on the module id in the constructor of `Mdoule`.
So this code path was probably broken for a while.

```txt
✖ ERROR: Error: Empty filepath.
    at pathDirname (ext:deno_node/01_require.js:245:11)
    at new Module (ext:deno_node/01_require.js:446:15)
    at Function.Module._resolveFilename (ext:deno_node/01_require.js:754:28)
    at Function.resolve (ext:deno_node/01_require.js:1015:19)
```
2023-03-27 21:54:22 +02:00
..
crypto fix(ext/node): add aes-128-ecb algorithm support (#18412) 2023-03-25 15:42:07 +09:00
polyfills fix(ext/node): add missing _preloadModules hook (#18447) 2023-03-27 21:54:22 +02:00
zlib feat: port node:zlib to rust (#18291) 2023-03-27 16:03:07 +00:00
Cargo.toml feat: port node:zlib to rust (#18291) 2023-03-27 16:03:07 +00:00
errors.rs chore: upgrade to Rust 1.67 (#17548) 2023-01-27 10:43:16 -05:00
idna.rs refactor: use ops for idna & punycode (#17817) 2023-02-20 18:47:42 +01:00
lib.rs feat: port node:zlib to rust (#18291) 2023-03-27 16:03:07 +00:00
ops.rs refactor(core): pass cwd explicitly to resolve_path (#18092) 2023-03-13 18:50:23 +01:00
package_json.rs feat(npm): support bare specifiers from package.json in more subcommands and language server (#17891) 2023-02-23 10:58:10 -05:00
path.rs chore(ext/node): fix variable name (#17948) 2023-02-27 21:26:02 +01:00
polyfill.rs refactor(ext/node): untangle dependencies between js files (#18284) 2023-03-20 14:05:13 -04:00
README.md chore(ext/node): correct publishing for ext/node (#15461) 2022-08-11 17:25:41 -04:00
resolution.rs refactor: simplify to string calls (#18011) 2023-03-04 08:05:07 -04:00
v8.rs feat(ext/node): implement node:v8 (#17806) 2023-02-17 18:48:09 +05:30
winerror.rs perf(ext/node): move winerror binding to rust (#17792) 2023-02-16 19:19:32 +05:30

deno_node

require and other node related functionality for Deno.