# Attachment URL: /docs/primitives/attachment File and image attachment rendering for the composer and messages. The Attachment primitive renders file and image attachments. It appears in two places: inside the composer for pending uploads (with a remove button), and inside messages for sent attachments (read-only). You provide the layout and styling. ```tsx import { AttachmentPrimitive, ComposerPrimitive, } from "@assistant-ui/react"; import { XIcon } from "lucide-react"; function ComposerAttachment() { return ( ); } ``` Quick Start \[#quick-start] An attachment inside a composer: ```tsx import { AttachmentPrimitive, ComposerPrimitive } from "@assistant-ui/react"; {() => } Send ``` `Root` renders a `
`, `unstable_Thumb` renders a `
` showing the file extension with a leading dot (e.g., `.pdf`), `Name` renders plain text, and `Remove` renders a `