---
title: "open(items:selectedItem:)"
framework: Quick Look
role: symbol
role_heading: Type Method
platforms: [visionOS 2.0+]
path: "quicklook/previewapplication/open(items:selecteditem:)"
---

# open(items:selectedItem:)

Previews the provided items.

## Declaration

```swift
final class func open(items: [PreviewItem], selectedItem: PreviewItem? = nil) -> PreviewSession
```

## Parameters

- `items`: An array of preview items to present in the new PreviewApplication scene.
- `selectedItem`: If provided and in the array of passed items, the preview item to select in the presented collection..

## Return Value

Return Value A PreviewSession instance.

## Discussion

Discussion This method launches the preview application with the provided preview items and, optionally, a selected item.
