Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Have the lwc package directly export types from @lwc/engine-dom #3598

Open
Tracked by #2964
nolanlawson opened this issue Jun 27, 2023 · 2 comments · May be fixed by #4186
Open
Tracked by #2964

Have the lwc package directly export types from @lwc/engine-dom #3598

nolanlawson opened this issue Jun 27, 2023 · 2 comments · May be fixed by #4186
Labels
BUG P3 enhancement typescript Typescript related bugs

Comments

@nolanlawson
Copy link
Contributor

Currently the lwc package has its own types:

declare module 'lwc' {
// backwards compatible type used for the old days when TS didn't support `event.composed`
interface ComposableEvent extends Event {
composed: boolean;
}

...which are kinda-sorta mimicking the types in @lwc/engine-dom. But they're not exactly the same.

Ideally we should just use something like:

export type * from '@lwc/engine-dom'

This way, we wouldn't need to duplicate the types, which leads to bugs like #3597.

@nolanlawson
Copy link
Contributor Author

This is potentially a quasi-breaking change, but our Nucleus downstreams should catch it if we mess anything up.

@nolanlawson nolanlawson added enhancement typescript Typescript related bugs BUG P3 labels Jul 5, 2023
@git2gus
Copy link

git2gus bot commented Jul 5, 2023

This issue has been linked to a new work item: W-13710310

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BUG P3 enhancement typescript Typescript related bugs
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant