microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
164.61k stars 29.42k forks source link

`handle: string` to `nativeHandle: UInt8Array` based on feedback #234378

Closed TylerLeonhardt closed 18 hours ago

TylerLeonhardt commented 18 hours ago

Feedback in https://github.com/microsoft/vscode/issues/229431

Extra tricky because UInt8Array's don't serialize nicely... and VSBuffers do, but only between Main and Window....

So we use VSBuffer between Main & Window and then a base64 encoded string between Window and the ExtHost.

Ultimately handing off a UInt8Array to the extension.