Skip to content

Commit f81a6ea

Browse files
authored
Merge pull request #28 from e2b-dev/fix-types
Fix types in the TypeScript SDK
2 parents 34bf07a + a2196db commit f81a6ea

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

.changeset/loud-memes-sleep.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@e2b/desktop": minor
3+
---
4+
5+
fixed types

packages/js-sdk/src/sandbox.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ export class Sandbox extends SandboxBase {
303303
* @returns A object with the x and y coordinates
304304
* @throws Error if cursor position cannot be determined
305305
*/
306-
async getCursorPosition(): Promise<CursorPosition | null> {
306+
async getCursorPosition(): Promise<CursorPosition> {
307307
const result = await this.commands.run(
308308
"xdotool getmouselocation", { envs: { DISPLAY: this.display } }
309309
);
@@ -328,7 +328,7 @@ export class Sandbox extends SandboxBase {
328328
* @returns An {@link ScreenSize} object
329329
* @throws Error if screen size cannot be determined
330330
*/
331-
async getScreenSize(): Promise<ScreenSize | null> {
331+
async getScreenSize(): Promise<ScreenSize> {
332332
const result = await this.commands.run(
333333
"xrandr", { envs: { DISPLAY: this.display } }
334334
);

0 commit comments

Comments
 (0)