New in React Native SDK 2.6.0, which needs the 2.6.0 native SDKs.
components map of the native SDKs is not in the React Native SDK.
Give the sheet your fonts
placement().appearance().
appearance() takes an AppearanceConfig: the brand colors, as the native placement takes them, and sheet. Fields of the wrong type are dropped, and the last call wins. With no heading marks in the sheet’s style, the heading font draws nothing.
Each name must be a font your native app already registers:
- iOS: a font listed under
UIAppFontsinInfo.plist. Pass a nameUIFont(name:)loads, such as its PostScript name. - Android: a font resource in
res/font(luckiestguy_regular, or the name in that form), or a file inassets/fontsnamed<name>.ttfor<name>.otf, where React Native’s linked fonts go. A font loaded only at run time, for example withexpo-font’suseFonts, is not found on Android.
res/font resource by name at run time, so release resource shrinking can remove a font that nothing else references. Keep them with android/app/src/main/res/raw/keep.xml:
Encore.placement(id).appearance(...) takes sheet. A trigger component’s appearance styles the trigger, and the sheet it opens does not take sheet, as in the native SDKs.
Styles from the Style editor and motion
Colors, corners, borders, images, and motion that the Style editor sets reach the sheet with no code. A Lottie animation plays only when your app links Lottie (lottie-ios 4.x on iOS, com.airbnb.android:lottie 5.2 or later on Android). Without it, the element draws as it did before 2.6.0.