Skip to content
napi-bindings

Search

Search pages, projects and the Node-API reference

Browse Node-APIshow

napi_create_array

functionv1js_native_api.h

This API returns a Node-API value corresponding to a JavaScript Array type. JavaScript arrays are described in Section Array objects of the ECMAScript Language Specification.

napi_status napi_create_array(napi_env env, napi_value* result)
  • [in] env: The environment that the Node-API call is invoked under.
  • [out] result: A napi_value representing a JavaScript Array.

Returns napi_ok if the API succeeded.

This API returns a Node-API value corresponding to a JavaScript Array type. JavaScript arrays are described in Section Array objects of the ECMAScript Language Specification.

View in the official Node.js documentation