From d3255cad8e2a6ba03629903743e166401fc3597e Mon Sep 17 00:00:00 2001 From: Gabriel Schulhof Date: Sat, 28 Apr 2018 17:38:09 -0400 Subject: [PATCH] n-api: document the look of napi_external values Describe what JavaScript values of type `napi_external` look like in JavaScript. Fixes: https://github.com/nodejs/abi-stable-node/issues/306 PR-URL: https://github.com/nodejs/node/pull/20426 Reviewed-By: Michael Dawson Reviewed-By: Vse Mozhet Byt --- doc/api/n-api.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/doc/api/n-api.md b/doc/api/n-api.md index bc0db26e352556..1ad9312b199cd2 100644 --- a/doc/api/n-api.md +++ b/doc/api/n-api.md @@ -1051,6 +1051,9 @@ the ECMAScript Language Specification. In addition to types in that section, `napi_valuetype` can also represent `Function`s and `Object`s with external data. +A JavaScript value of type `napi_external` appears in JavaScript as a plain +object such that no properties can be set on it, and no prototype. + #### napi_typedarray_type ```C typedef enum {