Skip to main content

brownie

Provides guidance for shared state in React Native brownfield apps with @callstack/brownie. Define stores in TypeScript, run brownfield codegen, use the generated APIs in React Native and native hosts, and package native artifacts for integration.

소스 정보

저장소
callstack/react-native-brownfield
최근 소스 활동
2026년 5월 12일 09:47
감지된 SKILL.md 언어
영어
스타
553
포크
58

설치 방법

기본적으로 소스를 먼저 확인하는 Prompt가 선택됩니다. 직접 명령으로 전환하거나 로컬 사본을 다운로드할 수도 있습니다.

소스 파일 검토

설치 여부를 결정하기 전에 SKILL.md와 SkillsMP에 표시된 보조 파일을 읽어 보세요.

파일 탐색기
6 개 파일

SKILL.md 표시 중

SKILL.md
소스 지침 · 읽기 전용 미리보기
name
brownie
description
Provides guidance for shared state in React Native brownfield apps with @callstack/brownie. Define stores in TypeScript, run brownfield codegen, use the generated APIs in React Native and native hosts, and package native artifacts for integration.
license
MIT
metadata
{"author":"Callstack","tags":"react-native, expo, brownfield, state-management, brownie"}
# Overview Brownie provides cross-platform shared state for React Native brownfield apps. The workflow starts from `*.brownie.ts` store definitions, runs `brownfield codegen` (or packaging commands that include codegen), then uses typed APIs on TypeScript, Android, and iOS sides. # When to Apply Reference this skill when: - Setting up `@callstack/brownie` in an existing brownfield app - Defining or changing store schemas in `*.brownie.ts` - Using `useStore`, `subscribe`, `getSnapshot`, or `setState` on the JS side - Registering and consuming stores in Android or iOS hosts - Packaging and embedding iOS frameworks that include Brownie # Quick Reference - Install Brownie: ```bash npm install @callstack/brownie ``` - Generate native types: ```bash npx brownfield codegen ``` - Packaging commands also include Brownie codegen: ```bash # iOS npx brownfield package:ios --scheme YourScheme --configuration Release # Android npx brownfield package:android --module-name :YourModuleName --variant release npx brownfield publish:android --module-name :YourModuleName ``` ## Routing (concern -> file) Concern | Read --------|------ Initial install, prerequisites, setup sequence, first integration pass | [`getting-started.md`](references/getting-started.md) `*.brownie.ts` schema rules, `BrownieStores` augmentation, type mapping, when to rerun codegen | [`store-definition-and-codegen.md`](references/store-definition-and-codegen.md) `useStore` selectors, update patterns, low-level APIs (`subscribe`, `getSnapshot`, `setState`) | [`typescript-usage.md`](references/typescript-usage.md) Android registration lifecycle, serializer options, package settings, build and publish flow | [`android-usage.md`](references/android-usage.md) Swift store registration and UI usage, plus XCFramework packaging and embedding | [`swift-and-xcframework.md`](references/swift-and-xcframework.md) ## Retrieval and Response Rules - Single-reference-first: choose exactly one primary reference from the table above that best matches the request before opening any other file. - Stop-after-sufficiency: once the required command/API is found for the request, stop reading additional references. - Cross-reference only when blocked: open a second reference only if the first one does not contain the needed command/API. - Testing-context response budget: - Return compact actionable steps only. - Use at most one code snippet. - Do not restate overview/scope/background sections.
GitHub에서 보기