<!--
{
  "availability" : [
    "iOS: -",
    "iPadOS: -",
    "visionOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "QuickLook",
  "identifier" : "/documentation/QuickLook/PreviewItem",
  "metadataVersion" : "0.1.0",
  "role" : "Structure",
  "symbol" : {
    "kind" : "Structure",
    "modules" : [
      "Quick Look"
    ],
    "preciseIdentifier" : "s:9QuickLook11PreviewItemV"
  },
  "title" : "PreviewItem"
}
-->

# PreviewItem

An item to preview in the preview application.

```
struct PreviewItem
```

## Topics

### Operators

[`static func == (PreviewItem, PreviewItem) -> Bool`](/documentation/QuickLook/PreviewItem/==(_:_:))

Returns a Boolean value that indicates whether two preview items are equal.

### Initializers

[`init(url: URL, displayName: String?, editingMode: EditingMode)`](/documentation/QuickLook/PreviewItem/init(url:displayName:editingMode:))

Create a preview item from a URL and, optionally, a displayName and editingMode.

### Instance Properties

[`let displayName: String?`](/documentation/QuickLook/PreviewItem/displayName)

An optional display name to present for the preview item.

[`let editingMode: EditingMode`](/documentation/QuickLook/PreviewItem/editingMode)

The editingMode for the preview item.

[`let id: UUID`](/documentation/QuickLook/PreviewItem/id)

The stable identity of the preview item.

### Instance Methods

[`func hash(into: inout Hasher)`](/documentation/QuickLook/PreviewItem/hash(into:))

Hashes the essential components of this value by feeding them into the given hasher.

## Relationships

### Conforms To

[`Hashable`](/documentation/Swift/Hashable)

[`Identifiable`](/documentation/Swift/Identifiable)

[`Equatable`](/documentation/Swift/Equatable)

[`SendableMetatype`](/documentation/Swift/SendableMetatype)

[`Sendable`](/documentation/Swift/Sendable)

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)