시작하기
설치 명령어와 이 플러그인의 전체 마크다운 가이드를 포함한 설정 프롬프트 복사하기.
Set up this Capacitor plugin in the project.
Use the package manager already used by the project.
Install these package(s): `@capgo/capacitor-persistent-account`
Run the required Capacitor sync/update step after installation.
Read this markdown guide for the full setup steps: https://raw.githubusercontent.com/Cap-go/website/refs/heads/main/apps/docs/src/content/docs/docs/plugins/persistent-account/getting-started.mdx
Use that guide for platform-specific steps, native file edits, permissions, config changes, imports, and usage setup.
If that guide references other docs pages, read them too.
설치
설치 제목AI-Assisted Setup을 사용하여 플러그인을 설치할 수 있습니다. AI 도구에 Capgo 스킬을 추가하려면 다음 명령어를 사용하세요:
npx skills add https://github.com/Cap-go/capgo-skills --skill capacitor-plugins그런 다음 다음 명령어를 사용하세요:
Use the `capacitor-plugins` skill from `Cap-go/capgo-skills` to install the `@capgo/capacitor-persistent-account` plugin in my project.만약 Manual Setup을 선호한다면, 다음 명령어를 실행하고 아래의 플랫폼별 지침을 따르세요:
bun add @capgo/capacitor-persistent-accountbunx cap syncImport
Import 섹션import { CapacitorPersistentAccount } from '@capgo/capacitor-persistent-account';API 개요
섹션: API 개요readAccount
섹션: readAccount저장된 계정 데이터를 영구 저장소에서 읽습니다.
이 섹션에서는 이전에 saveAccount()를 사용하여 저장된 계정 데이터를 검색합니다. 데이터는 앱 세션을 넘어survives 앱 재설치에 지원되는 플랫폼에서 지속됩니다.
import { CapacitorPersistentAccount } from '@capgo/capacitor-persistent-account';
const result = await CapacitorPersistentAccount.readAccount();if (result.data) { console.log('Account data:', result.data);} else { console.log('No account data found');}saveAccount
saveAccount계정 데이터를 지속적인 저장소에 저장합니다.
플랫폼에 따라 안전한 저장소 메커니즘을 사용하여 제공된 계정 데이터를 저장합니다. 데이터는 앱 세션을 넘어survives 앱 재설치에 지원되는 플랫폼에서 지속됩니다. 기존 계정 데이터는 덮어씌워집니다.
import { CapacitorPersistentAccount } from '@capgo/capacitor-persistent-account';
await CapacitorPersistentAccount.saveAccount({ data: { userId: '12345', username: 'john.doe', email: 'john@example.com' }});실질적인 데이터 원천
Source Of Truth이 페이지는 플러그인의 src/definitions.tspublic API이 업스트림에서 변경될 때 다시 싱크를 실행하세요.
Getting Started에서 계속하세요
Keep going from Getting StartedCapgo를 사용 중이라면 시작하기 대시보드와 API 연산을 계획하고 싶다면 Capgo를 사용하여 @capgo/capacitor-persistent-account Capgo를 사용하여 @capgo/capacitor-persistent-account API 개요 API 개요 소개 소개 API 키 API 키 장치 장치에 대한 구현 세부 정보를 위해.