microsoft / microsoft/node-api-dotnet

`Memory<T>` to `TypedArray<T>` on Electron 19.1.9 Worked fine. But did not worked on higher Electron

Open
#383 7 comments 0 reactions 1 assignee View on GitHub

@jasongin is already working on this.

Since Sep 30, 2024.

electron marshalling
Dominant language
C#
Stars
783
Forks
80
PR merge metrics
No merged PRs in 30d

Description

I Test Memory<T> to TypedArray<T> on Electron 19.1.9,That Worked fine and has amazing Performance.
But when I Test on higher Electron, such as 32.1.2, it was not worked. And reported an error:

External buffers are not allowed: Error in CreateExternalArrayBuffer at D:\a\1\s\src\NodeApi\JSValue.cs:264

I did some research,the use of External buffers has actually been officially banned.
https://github.com/electron/electron/issues/35801

Does anyone know how to turn on External buffers support in the new version of Electron? Like turn it on by some command parameter or something。

Or has any Other way to transfer big data(such as 100MB) from dotnet to nodejs?

Originally posted by @Hiwen in https://github.com/microsoft/node-api-dotnet/issues/15#issuecomment-2381078420

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.