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: [BREAKING] Use default name for components with setup script and nameless compon… #1066

Merged

Conversation

khalilst
Copy link
Contributor

This PR in the following of issue #806 replaces the anonymous naming with the default component name:

So the following component's stub name will be script-setup-stub:

//filename: ScriptSetup.vue
<script setup>
...
</script>

Also, the same approach works on nameless components.
The test coverage applied for this fix.

Copy link
Member

@cexbrayat cexbrayat left a comment

Choose a reason for hiding this comment

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

Thanks @khalilst for the PR!

LGTM, but I'd like another pair of eyes before merging this.

@cexbrayat
Copy link
Member

@lmiller1990 @xanf @afontcu I added you as reviewers, as I don't know if that's too breaking or OK to merge. What do you think?

@khalilst
Copy link
Contributor Author

khalilst commented Nov 12, 2021

@cexbrayat
My pleasure (^_^)
Sure, you need to check it precisely. Just for your consideration, I've applied it in a local test env and everything works fine.

Copy link
Member

@lmiller1990 lmiller1990 left a comment

Choose a reason for hiding this comment

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

I think this makes sense. Bit of a breaking change for snapshots, but this seems like a overall improvement.

@lmiller1990 lmiller1990 changed the title Use default name for components with setup script and nameless compon… fix: [BREAKING] Use default name for components with setup script and nameless compon… Nov 14, 2021
@lmiller1990 lmiller1990 merged commit 0a8e02c into vuejs:master Nov 14, 2021
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