Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: added some warnings for buffer and array buffer factory method. #929

Merged
merged 3 commits into from
Mar 22, 2021

Conversation

NickNaso
Copy link
Member

Fixes: #258
This PR add some warnings on documentation for:

static Napi::Buffer<T> Napi::Buffer::New(napi_env env, T* data, size_t length);
static Napi::ArrayBuffer Napi::ArrayBuffer::New(napi_env env, void* externalData, size_t byteLength);

Copy link
Member

@mhdawson mhdawson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

doc/array_buffer.md Outdated Show resolved Hide resolved
doc/array_buffer.md Outdated Show resolved Hide resolved
doc/array_buffer.md Outdated Show resolved Hide resolved
doc/array_buffer.md Outdated Show resolved Hide resolved
doc/buffer.md Outdated Show resolved Hide resolved
doc/buffer.md Outdated Show resolved Hide resolved
doc/buffer.md Outdated Show resolved Hide resolved
doc/buffer.md Outdated Show resolved Hide resolved
@NickNaso NickNaso added the doc label Mar 16, 2021
Copy link
Contributor

@gabrielschulhof gabrielschulhof left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some minor nits.

doc/array_buffer.md Outdated Show resolved Hide resolved
doc/array_buffer.md Outdated Show resolved Hide resolved
@mhdawson mhdawson merged commit 8ef0725 into nodejs:main Mar 22, 2021
deepakrkris pushed a commit to deepakrkris/node-addon-api that referenced this pull request Sep 23, 2021
deepakrkris pushed a commit to deepakrkris/node-addon-api that referenced this pull request Oct 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

External data lifetime for Buffer and ArrayBuffer
3 participants