搜尋套件、儲存庫與 APP 分類

套件詳情v1.8.1

appcheck

Flutter 插件,可讓您檢查應用程式是否已安裝/啟用、啟動應用程式並取得已安裝應用程式的清單。

AndroidiOS
近 30 天下載
5萬
喜歡數
135
Pub 分數
160

安裝套件

flutter pub add appcheck

套件介紹

根據套件公開資料產生的選型評估,僅供參考。

AppCheck 是一個 Flutter 插件,讓開發者能夠檢測應用程式是否安裝或啟用於 Android 與 iOS 裝置上。它允許透過套件名稱啟動特定應用程式,並取得已安裝應用程式的清單。專為跨平台相容性設計,無需原生程式碼即可簡化與裝置層級應用資料的互動。適用於深度連結、應用推薦或與第三方服務整合等功能。此插件輕量且可透過簡單的 pub add 命令順暢整合至 Flutter 項目中。

適用情境

  • 檢查特定應用是否已安裝
  • 從當前應用程式內啟動另一個應用程式
  • 取得已安裝應用程式清單
  • 啟用基於應用程式的工作流程
  • 支援深度連結場景
  • 與外部應用生態系統整合

主要特色

  • 跨平台支援(Android 與 iOS)
  • 用於應用檢測的簡單 API
  • 透過套件名稱啟動應用程式的能力
  • 回傳已安裝應用程式清單
  • 輕量且易於整合
  • 無需撰寫原生程式碼

適合對象

  • 開發應用程式整合的開發者
  • 需要深度連結功能的應用
  • 推薦或觸發其他應用的工具
  • 需要設備應用存取權限的混合應用程式
  • 專注於使用者體驗增強的專案
  • 具有生態系統依賴關係的行動應用程式

使用建議

  • 僅限 Android 與 iOS 平台
  • 需要正確的应用程式套件名稱
  • 由於安全限制,可能無法與所有應用程式搭配使用
  • 某些裝置可能需要權限
  • 行為在 Android 和 iOS 之間略有差異
  • 不適用於存取安裝狀態以外的應用程式資料

原始 README

以下為關聯原始碼儲存庫的 README 原文快照,最新內容請造訪原始碼儲存庫。

AppCheck

Pub

A Flutter plugin that allows you to check if an app is installed/enabled, launch an app and get the list of installed apps.

Installation

First, add appcheck as a dependency in your pubspec.yaml file.

Methods available

  • checkAvailability(String uri)
  • isAppInstalled(String uri)
  • getInstalledApps() (only for Android)
  • isAppEnabled(String uri) (only for Android)
  • launchApp(String uri)

Permissions

Before using the plugin, you need to add declarations in your configuration files.

Android

If you want to use the getInstalledApps() function, you need the QUERY_ALL_PACKAGES permission.

<uses-permission android:name="android.permission.QUERY_ALL_PACKAGES" />

If you only want to check certain apps and you know the packageName, add them via queries in AndroidManifest.xml.

<queries>
   <package android:name="com.google.android.apps.maps"/>
</queries>
iOS

Make sure your Info.plist file includes the necessary URL schemes under LSApplicationQueriesSchemes to check and launch other apps:

<key>LSApplicationQueriesSchemes</key>
<array>
    <string>scheme1</string>
    <string>scheme2</string>
    <!-- Add more schemes as needed -->
</array>

Example:

<key>LSApplicationQueriesSchemes</key>
<array>
    <string>fb</string>
    <string>twitter</string>
    <string>instagram</string>
    <string>whatsapp</string>
    <string>youtube</string>
    <string>comgooglemaps</string>
    <string>http</string>
    <string>https</string>
    <string>mailto</string>
    <!-- Add more schemes as needed -->
</array>

Check out Example.

Screenshots

所屬分類

原始碼儲存庫

使用此套件的專案