chore: remove node patches by using the preload feature (#41080)

This commit is contained in:
Cheng Zhao
2024-01-25 00:54:32 +09:00
committed by GitHub
parent 031d636823
commit d13a93fb61
21 changed files with 403 additions and 135 deletions

View File

@@ -219,6 +219,12 @@ class NodeBindings {
base::WeakPtrFactory<NodeBindings> weak_factory_{this};
};
// A thread-safe function responsible for loading preload script which runs for
// all node environments (including child processes and workers).
void OnNodePreload(node::Environment* env,
v8::Local<v8::Value> process,
v8::Local<v8::Value> require);
} // namespace electron
#endif // ELECTRON_SHELL_COMMON_NODE_BINDINGS_H_