---
title: touchBar
framework: appkit
role: symbol
role_heading: Instance Property
path: appkit/nstouchbarprovider/touchbar
---

# touchBar

The property you implement to provide a Touch Bar object.

## Declaration

```swift
@MainActor var touchBar: NSTouchBar? { get }
```

## Discussion

Discussion This property supports key-value observing, which is used by the system, for example, if you replace a running bar. Many subclasses of NSResponder implement this property and conform to the NSTouchBarProvider protocol.
