App Clip Trilogy

  1. Learn how to create a good App Clip in iOS14
  2. Create a little Apple App, App Clip, what you should know
  3. How to make your App Clip have a good user experience

preface

HelloWord link: original

App Clip is a lightweight version of the App application that provides certain functions where and when the user wants them. In Xcode, App Clip is an additional Target that shares code and resources with your main application. App Clip can also access the same frameworks as App. For example, your App Clip can request access to a camera, store sensitive data in a local keystring, connect to a Bluetooth device, and so on. However, on the premise of protecting user privacy and preserving resources, App Clip also has some limitations.

Scenario using App Clip

The user launches the App clip by executing the call:

  • Scan the NFC label or QR code at a physical location
  • Choose Siri’s location-based suggestions, such as location
  • Click the link in the Map application
  • Click on a smart App Banner on the website
  • Click on a link someone shares in the iMessage app

When a user invokes App Clip, the system authenticates the metadata of the App Clip and its associated URL. Then, we use the URL to determine what data to display on the App Clip card (which is a Sheet view that pops up at the bottom after we call it). The App Clip Card provides a lot of information and provides a button that the user clicks to launch the application clip.

When the user launches the App Clip, the URL is passed to it. When started, App Clip accesses the URL and parses it to extract information, which is then used to update its user interface.

Enhance the user experience

App Clip does not appear on the home screen and users cannot manage it in the same way they manage the App. Instead, the App Clip is removed from the device after a period of inactivity. Therefore, it is very important to provide a great user experience for your App Clip.

App Clip should avoid complex interface elements (such as TAB bars or complex forms) to provide a linear, focused user experience. Reduce the use of complex techniques when requiring users to perform complex tasks. For example, using Apple Pay in App Clip to Pay a fee, or using Sign in with Apple to avoid complicated user logins.

Keep Your App Clip Small

The size of the App Clip must not exceed 10 MB to provide instant boot. If possible, keep your application clips below this limit.

Available frames for App Clip

App Clip can use SwiftUI and UIKit and has access to the same framework as a full App. However, the following frameworks do not apply to App Clip: CallKit, CareKit, CloudKit, HealthKit, HomeKit, ResearchKit, SensorKit and Speech.

Using any of these frameworks in App Clip will not cause compile-time errors, but their apis will return values indicating run-time availability, empty data, or error code. For example, HealthKit’s isHealthDataAvailable () returns false when you call it from an application clip.

User privacy

App clip can use SKOverlay or SKStoreProductViewController display advertising and recommend other applications. However, always enable Limited Application Tracking in App Clip to protect user privacy and prevent users from tracking across applications and App Clips.

App Clip cannot track users through AppTrackingTransparency request authorization, and both name and identifierForVendor return an empty string. In addition, App Clip cannot perform background activities, such as using URLSession for background network connections or maintaining bluetooth connections when App Clip is not in use. App Clip also cannot request continuous access to location information. However, they may request When In Use authorization, which is automatically reset at 4 am the next day.

To protect user data, App Clip cannot access:

  • Sports and fitness data
  • Apple Music and Media
  • Data from applications such as contacts, files, messages, reminders, and photos

App Clip cannot share data with any application other than its own corresponding application.

Reserve some functionality for your main application

App Clip provides an immediate experience and focuses on providing the fastest solution for everyday tasks, but certain features are not available for App Clip:

  • Bonjour and other advanced networking features, or local Wi-Fi network configuration
  • App extensions
  • Customization and Settings; For example, create a Settings bundle
  • Data transfer and file opening
  • IAP and payment card configuration
  • Low-level Unix functionality; For example, BSD notifications
  • The split screen
  • Register custom URL Schemes
  • StoreKit’s requestReview (in 😃) asks users to review the app
  • Search for paired Bluetooth devices

At the end

So that’s the end of the article. Next we’ll show you how to create an App clip.


As an ios developer, when I encounter problems, it is particularly important to have a learning atmosphere and a communication circle, which is of great help to myself. This is my ios communication group: 711315161, sharing BAT, Ali interview questions, interview experience, discussing technology, and learning and growth together! Hope to help developers avoid detours.