Contents

presentationContext

The context describing where your iMessage app is presented.

Declaration

var presentationContext: MSMessagesAppPresentationContext { get }

Mentioned in

Discussion

By default, the system only displays iMessage apps in the MSMessagesAppPresentationContext.messages context (the iMessage app only appears inside the Messages app). iMessage apps in the media context have additional limitations and design considerations.

You can control the supported contexts by adding the MSSupportedPresentationContexts key to the iMessage app extension’s Info.plist file. For example, presentationContext enables the iMessage app in effects in Messages and FaceTime.

<key>MSSupportedPresentationContexts</key>
<array>
  <string>MSMessagesAppPresentationContextMessages</string>
  <string>MSMessagesAppPresentationContextMedia</string>
</array>

See Also

Working with Presentation Styles and Contexts