Skip to content
napi-bindings

Search

Search pages, projects and the Node-API reference

Browse Node-APIshow

napi_get_boolean

functionv1js_native_api.h

This API is used to return the JavaScript singleton object that is used to represent the given boolean value.

napi_status napi_get_boolean(napi_env env, bool value, napi_value* result)
  • [in] env: The environment that the API is invoked under.
  • [in] value: The value of the boolean to retrieve.
  • [out] result: napi_value representing JavaScript Boolean singleton to retrieve.

Returns napi_ok if the API succeeded.

This API is used to return the JavaScript singleton object that is used to represent the given boolean value.

View in the official Node.js documentation