Skip to content

[🐛 Bug]: getSize() typing expects at least 1 argument #12173

@therealbrad

Description

@therealbrad

Have you read the Contributing Guidelines on issues?

WebdriverIO Version

latest

Node.js Version

latest

Mode

WDIO Testrunner

Which capabilities are you using?

No response

What happened?

When using getSize() in TypeScript I get a compile error:
Expected 1 arguments, but got 0.

What is your expected behavior?

getSize() argument is optional.

How to reproduce the bug.

https://github.com/therealbrad/wdio-getsize shows the bug
Note the test passes, but TypeScript complains:

Property 'height' does not exist on type 'number'.
Property 'width' does not exist on type 'number'.```

### Relevant log output

```typescript
Expected 1 arguments, but got 0.
Property 'height' does not exist on type 'number'.
Property 'width' does not exist on type 'number'.

Code of Conduct

  • I agree to follow this project's Code of Conduct

Is there an existing issue for this?

  • I have searched the existing issues

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bug 🐛help wantedIssues that are free to take by anyone interested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions