Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/nodejs/node-addon-api
/ Init
Function
Init
test/addon_build/tpl/addon.cc:13–16 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
11
}
12
13
Napi::Object Init(Napi::Env env, Napi::Object exports) {
14
exports.Set(Napi::String::New(env,
"echo"
), Napi::Function::New(env, Echo));
15
return exports;
16
}
17
18
NODE_API_MODULE(NODE_GYP_MODULE_NAME, Init)
Callers
2
InitThreadSafeFunctionCtx
Function · 0.50
InitTypedThreadSafeFunctionCtx
Function · 0.50
Calls
1
Set
Method · 0.80
Tested by
no test coverage detected