Skip to content

[💡 Feature]: Replace current build system with Vite #11713

@colinrotherham

Description

@colinrotherham

Is your feature request related to a problem?

This issue is a follow up to comment #11712 (comment)

Some older browsers configured in capabilities throw errors when running scripts from webdriverio/src/scripts, is this something we could solve or prevent using automation?

I've added some suggestions below

Script errors in older browsers

For example, I've fixed some element method issues in older Firefox and IE11:

I'm getting there, but some are still failing:

See GitHub Actions logs and Sauce Labs output for more info

[internet explorer 11 windows #2-0] 25 passing (2m 3.7s)
[internet explorer 11 windows #2-0] 6 failing

Describe the solution you'd like.

Since the scripts in webdriverio/src/scripts are TypeScript, could we target an older ECMAScript version?

They're currently using TypeScript "target": "es2022"

Describe alternatives you've considered.

  1. Using TypeScript "target": "es5" or lower for downleveling (and warnings)
  2. Using ESLint with eslint-plugin-es-x to check syntax against ecmaVersion
  3. Using Babel presets to transform scripts without heavy polyfills
  4. Using Internet Explorer 11 as a "token old browser" in E2E tests

Additional context

What tests could be added to prevent unsupported syntax from being added again in future?

Code of Conduct

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions