Skip to content

feat(component-meta): add tags to slots and exposed#5862

Merged
johnsoncodehk merged 3 commits intovuejs:masterfrom
aj-dev:feat/resolve-jsdoc-tags-in-slots-and-exposed
Dec 13, 2025
Merged

feat(component-meta): add tags to slots and exposed#5862
johnsoncodehk merged 3 commits intovuejs:masterfrom
aj-dev:feat/resolve-jsdoc-tags-in-slots-and-exposed

Conversation

@aj-dev
Copy link
Contributor

@aj-dev aj-dev commented Dec 12, 2025

This PR adds tags to slots and exposed so that jsDoc tags can be used consistently across props, events, slots and exposed.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds support for JSDoc tags to slot and exposed property metadata, bringing them into alignment with the existing tags support for props and events. The changes enable developers to use JSDoc tags (like @deprecated) consistently across all component metadata types.

  • Adds tags field to SlotMeta and ExposeMeta interfaces
  • Refactors tag extraction into a reusable getJsDocTags helper function
  • Updates test files and snapshots to demonstrate tag extraction from reference types

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
packages/component-meta/lib/types.ts Adds tags field to SlotMeta and ExposeMeta interfaces; also includes unrelated field reordering in PropertyMeta
packages/component-meta/lib/base.ts Implements getJsDocTags helper function and applies it to slot and exposed property resolvers
packages/component-meta/tests/index.spec.ts Adds test assertions to verify tag extraction for slots and exposed properties
test-workspace/component-meta/reference-type-slots/my-slots.ts New test file defining slot interface with JSDoc tags
test-workspace/component-meta/reference-type-slots/component-define-slots.vue Refactored to use external MySlots type for testing tag extraction
test-workspace/component-meta/reference-type-exposed/my-exposed.ts New test file defining exposed interface with JSDoc tags
test-workspace/component-meta/reference-type-exposed/component.vue Refactored to use external MyExposed type for testing tag extraction
packages/tsc/tests/snapshots/dts.spec.ts.snap Updated snapshots reflecting the new type definitions and reference imports
README.md Unrelated documentation improvements (comma additions and command corrections)

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

johnsoncodehk and others added 2 commits December 13, 2025 08:51
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@johnsoncodehk johnsoncodehk linked an issue Dec 13, 2025 that may be closed by this pull request
@johnsoncodehk
Copy link
Member

LGTM, thanks for the PR!

@johnsoncodehk johnsoncodehk merged commit a144b6b into vuejs:master Dec 13, 2025
4 checks passed
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.

(vue-component-meta) Support tags for slots and expose

2 participants