Skip to content

1681-engine / electron / denyPermissions

Function: denyPermissions() ​

ts
function denyPermissions(session, allow?): void;

Defined in: src/electron/lockdown.ts:61

Answers every permission request and check on session (camera, microphone, notifications, geolocation…) with no, but those in allow. Chromium's default in Electron is yes to almost everything, which a game never needs.

Parameters ​

ParameterTypeDefault value
sessionSessionLikeundefined
allowreadonly string[][]

Returns ​

void

Released under the MIT License.