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

Fix type declarations inadvertently referencing Polymer.Element. #5084

Merged
merged 1 commit into from
Feb 1, 2018

Conversation

aomarks
Copy link
Member

@aomarks aomarks commented Feb 1, 2018

Polymer defines its own Element class, shadowing the standard global Element class. This means that references to Element within the Polymer namespace inadvertently reference Polymer.Element. Here we define an alias of the global Element (called _Element), so that we can reference it from declarations within the Polymer namespace.

See microsoft/TypeScript#983 for general discussion of this shadowing problem in TypeScript.

Fixes #5074

Polymer defines its own `Element` class, shadowing the standard global
`Element` class. This means that references to `Element` within the
`Polymer` namespace inadvertently reference `Polymer.Element`. Here we
define an alias of the global `Element`, so that we can reference it
from declarations within the `Polymer` namespace.

See microsoft/TypeScript#983 for general
discussion of this shadowing problem in TypeScript.

Fixes #5074
@aomarks aomarks merged commit 82cd3da into master Feb 1, 2018
@aomarks aomarks deleted the element-shadow branch February 1, 2018 21:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants