diff --git a/.changeset/two-carrots-smile.md b/.changeset/two-carrots-smile.md new file mode 100644 index 000000000000..d5b046b0bdb3 --- /dev/null +++ b/.changeset/two-carrots-smile.md @@ -0,0 +1,17 @@ +--- +'astro': minor +--- + +Added `Polymorphic` type helper to `astro/types` to easily create polymorphic components: + +```astro +--- +import { HTMLTag, Polymorphic } from 'astro/types'; + +type Props = Polymorphic<{ as: Tag }>; + +const { as: Tag, ...props } = Astro.props; +--- + + +```