diff options
author | Michael Dawson <michael_dawson@ca.ibm.com> | 2019-09-04 22:18:26 +0300 |
---|---|---|
committer | Michaƫl Zasso <targos@protonmail.com> | 2019-09-20 10:36:20 +0300 |
commit | a9d16b5e304e46cc964bd2d5cc534b5e030c2468 (patch) | |
tree | d5ab78fd655a24dbc598aee7d32787de84b02d9e /doc/api | |
parent | fa949ca36577931030d99162b6e945c275a478bc (diff) |
doc: simplify wording in n-api doc
Simplify/clarify wording documenting n-api execute
callback.
PR-URL: https://github.com/nodejs/node/pull/29441
Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Diffstat (limited to 'doc/api')
-rw-r--r-- | doc/api/n-api.md | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/doc/api/n-api.md b/doc/api/n-api.md index 7a95cea8c8d..e98342668b3 100644 --- a/doc/api/n-api.md +++ b/doc/api/n-api.md @@ -548,12 +548,12 @@ operations. Callback functions must satisfy the following signature: typedef void (*napi_async_execute_callback)(napi_env env, void* data); ``` -Implementations of this type of function should avoid making any N-API calls -that could result in the execution of JavaScript or interaction with -JavaScript objects. Most often, any code that needs to make N-API -calls should be made in `napi_async_complete_callback` instead. -Avoid using the `napi_env` parameter in the execute callback as -it will likely execute JavaScript. +Implementations of this function must avoid making N-API calls +that execute JavaScript or interact with +JavaScript objects. N-API +calls should be in the `napi_async_complete_callback` instead. +Do not use the `napi_env` parameter as it will likely +result in execution of JavaScript. #### napi_async_complete_callback <!-- YAML |