diff options
author | David Sherret <dsherret@users.noreply.github.com> | 2022-08-23 10:39:19 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-23 10:39:19 -0400 |
commit | e7367044d933ee3518ae583a43876a0ddab5b17e (patch) | |
tree | e557e3ea4faad632bcfafa6539f3bd0115dc6426 /cli/compat/mod.rs | |
parent | 362af63c6f45e98948536d08d2d6195af87f729c (diff) |
feat: binary npm commands (#15542)
Diffstat (limited to 'cli/compat/mod.rs')
-rw-r--r-- | cli/compat/mod.rs | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/cli/compat/mod.rs b/cli/compat/mod.rs index ab8a1ff2d..02fdb5604 100644 --- a/cli/compat/mod.rs +++ b/cli/compat/mod.rs @@ -112,24 +112,6 @@ pub fn try_resolve_builtin_module(specifier: &str) -> Option<Url> { } } -#[allow(unused)] -pub fn load_cjs_module_from_ext_node( - js_runtime: &mut JsRuntime, - module: &str, - main: bool, -) -> Result<(), AnyError> { - let source_code = &format!( - r#"(function loadCjsModule(module) {{ - Deno[Deno.internal].require.Module._load(module, null, {main}); - }})('{module}');"#, - main = main, - module = escape_for_single_quote_string(module), - ); - - js_runtime.execute_script(&located_script_name!(), source_code)?; - Ok(()) -} - pub fn load_cjs_module( js_runtime: &mut JsRuntime, module: &str, |