Skip to content
This repository has been archived by the owner on Mar 27, 2023. It is now read-only.

fix(core): lit lifecycle type #6667

Merged
merged 1 commit into from
Feb 9, 2022
Merged

fix(core): lit lifecycle type #6667

merged 1 commit into from
Feb 9, 2022

Conversation

coryrylan
Copy link
Contributor

PR Checklist

Please check if your PR fulfills the following requirements:

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been added / updated (for bug fixes / features)
  • If applicable, have a visual design approval

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Documentation content changes
  • clarity.design website / infrastructure changes
  • Other... Please describe:

What is the current behavior?

Lit released a non-backwards compatible change to a TS type on the LitElement base class. This type is more accurate but causes a build error if a downstream component implements the type incorrectly. This caused any project not using pinned dependencies (stackblitz primarily) to start breaking when using Core.

Issue Number:
#6654
lit/lit#2513

What is the new behavior?

This updates all lifecycle hooks to use the correct PropertyValues type

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

- fixes change from upstream lit release
- closes #6654

Signed-off-by: Cory Rylan <splintercode.cb@gmail.com>
@coryrylan coryrylan self-assigned this Feb 9, 2022
@@ -99,7 +99,7 @@ export class CdsInternalControlInline extends CdsControl {
);
}

updated(props: Map<string, any>) {
updated(props: PropertyValues<any>) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are the others PropertyValues<this> but this one is PropertyValues<any>?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@coryrylan coryrylan merged commit efbf0f0 into next Feb 9, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants