跳过内容

Getting Started

GitHub
终端窗口
npm install @capgo/capacitor-native-market
npx cap sync
import { NativeMarket } from '@capgo/capacitor-native-market';

在Play Store(Android)或App Store(iOS)中打开应用清单页面。

import { NativeMarket } from '@capgo/capacitor-native-market';
// Open app in store
await NativeMarket.openStoreListing({
appId: 'com.example.app'
});
// Open app in specific country store (iOS only)
await NativeMarket.openStoreListing({
appId: 'com.example.app',
country: 'IT'
});

直接深度链接到Play Store中的开发者页面。 仅限Android。

import { NativeMarket } from '@capgo/capacitor-native-market';
await NativeMarket.openDevPage({
devId: 'Google+LLC'
});

将用户链接到Play Store中的收藏或热门榜。 仅限Android。

import { NativeMarket } from '@capgo/capacitor-native-market';
await NativeMarket.openCollection({
name: 'featured'
});

在 Google Play 商店中链接到编辑推荐页面。 仅限 Android。

import { NativeMarket } from '@capgo/capacitor-native-market';
await NativeMarket.openEditorChoicePage({
editorChoice: 'editorial_fitness_apps_us'
});

使用自定义搜索词在 Google Play 商店中搜索。 仅限 Android。

import { NativeMarket } from '@capgo/capacitor-native-market';
await NativeMarket.search({
terms: 'fitness apps'
});

该页面是从插件生成的。 重新运行同步时,公共 __CAPGO_KEEP_0__ 上游发生变化。 src/definitions.ts. Re-run the sync when the public API changes upstream.

Section titled “继续从 Getting Started”

Section titled “Source Of Truth”

如果您正在使用 入门 为了计划仪表板和API操作,连接它与 使用@capgo/capacitor-native-market 在使用@capgo/capacitor-native-market中 API概述 在API概述中 介绍 在介绍中 API密钥 在API密钥中 设备 __CAPGO_KEEP_0__详细信息