Reader Modal

Overview

Apple allows apps that are primarily offering digital content such as magazines, newspapers, books, audio, music, or video to link to their website externally of the app for account management and payments. The Reader Modal plugin allows you to implement this functionality in your app.

To able to offer this functionality within your app you need special permission from Apple to use the External Link Account entitlement. Apple Documentation.

Implementation Guide

Check if the user can make payments

Before you can open your website link you need to make sure that the user is actually allowed to make purchases on this device. You can do this using the following JavaScript Bridge method:

↔️Median JavaScript Bridge

const { canMakePayments } = await median.readerModal.canMakePayments();

Showing the modal

Once you have the confirmation that the user can make purchases you can show the modal to the user using the following JavaScript Bridge method:

↔️Median JavaScript Bridge

median.readerModal.showModal();

The modal will display as follows on devices running iOS 16+

👍

Developer Demo

Display our demo page in your app to test during development https://median.dev/reader-modal/