(webdriverio): remove type exports#11590
Conversation
|
@christian-bromann This is a breaking change for folks that used the previously-exported types. I definitely understand the desire to avoid multiple definitions and think it's reasonable to collapse down to 1 exposed set of typings, but it should be done in a breaking change release, not a bugfix. |
|
I disagree this being a breaking change since we never documented nor advertised the use of these types. |
|
Of course, it's your project and it's your prerogative to decide what should constitute a breaking change for it, but please understand that many reasonable folks will consider "a type that is exported from the package's index" to be an advertised part of the package's API, regardless of explicit documentation about it. Realistically, more folks discover types through IDE auto-completion than through documentation. In actual practice, you can find 1000+ cases that this would break between the following two GitHub code search queries (which are not exhaustive): Is it truly so important to get this change in now, rather than waiting for the next major version, that it's worth breaking 1000+ known usages? |
|
@dbjorge you are making a good point! I am surprised it is used that much. I reverted the change and added a deprecation warning. |
Proposed changes
We currently export all WebdriverIO types from the module, including the ones for
BrowserandElement. These are not meant to be used for public consumption, instead folks should use theWebdriverIOnamespace, e.g.WebdriverIO.Browser.Types of changes
Checklist
Further comments
fixes #11055
Reviewers: @webdriverio/project-committers