How adaptyteam/adaptyui-react-native works
Project type and purpose
• This is an open-source React Native UI library (“@adapty/react-native-ui”) that extends the Adapty SDK by providing a native, no-code paywall view component for iOS and Android.
• It is not a full-stack app; it’s a client-side library that installs into a RN project, bridges JS ↔ native, and fetches/render paywalls via the Adapty SDK.
File structure
• Top-level: configuration files (.eslintrc, babel.config.js, tsconfig.json), CI workflows (.github), scripts/pack.sh.
• “src/” contains the JS/TS bridge:
• bridge.ts – entry point to the native module
• index.tsx – exports public API (createPaywallView)
• view-controller.ts & view-emitter.ts – manage view lifecycle and events
• types/ – TypeScript definitions for bridge and public types
• “android/”: standard RN native-module Android code under src/main/java/com/adapty/react/ui
• “ios/”: native UI module implementation in Swift/Obj-C plus Xcode project
• package.json and podspec define how the library integrates into RN projects.
README for additional insights
• Explains usage: fetch paywall via Adapty SDK JS module, then call createPaywallView → returns a platform-native view object.
• The view object exposes present/dismiss and event handlers, which under the hood invoke native code and communicate back to JS.