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(types): fix ThisType of component options with no props option #7132

Closed
wants to merge 1 commit into from

Conversation

wadetandy
Copy link

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • Feature
  • Code style update
  • Refactor
  • Build-related changes
  • Other, please describe:

Does this PR introduce a breaking change? (check one)

  • Yes
  • No

If yes, please describe the impact and migration path for existing applications:

The PR fulfills these requirements:

If adding a new feature, the PR's description includes:

  • A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)

It seems that @ktsn and I had the same problem at the same time, as I separately found and fixed the problem identified in #7131 with this PR. I noticed @HerringtonDarkholme had open questions about the never type. My solution to the problem was a separate overload for Vue.extend and Vue.component that involves a third typed props type. I'm not expert enough on typescript to know which of these is a better solution, but I figured I'd open the duplicate-ish PR since I had a different approach in case you prefer it.

@HerringtonDarkholme
Copy link
Member

Thanks for your contribution!

After investigation, I think never type shouldn't be the issue. And @ktsn 's solution is arguably more succinct. So I hope you wouldn't mind if this pull request is going to be closed.

Thank you any way for this pull request!

@yyx990803
Copy link
Member

ref: #7135

Thanks for the PR though!

@yyx990803 yyx990803 closed this Nov 27, 2017
@wadetandy
Copy link
Author

@HerringtonDarkholme as long as we have a fix in place I'm happy 😄 . Thanks for all the hard work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants