diff --git a/releases/next/docs/platform-specific-code.html b/releases/next/docs/platform-specific-code.html index b304fdc1ac7..af9c3605ced 100644 --- a/releases/next/docs/platform-specific-code.html +++ b/releases/next/docs/platform-specific-code.html @@ -1,4 +1,4 @@ -
When building a cross-platform app, you'll want to re-use as much code as possible. Scenarios may arise where it makes sense for the code to be different, for example you may want to implement separate visual components for iOS and Android.
React Native provides two ways to easily organize your code and separate it by platform:
Platform module.Certain components may have properties that work on one platform only. All of these props are annotated with @platform and have a small badge next to them on the website.
React Native provides a module that detects the platform in which the app is running. You can use the detection logic to implement platform-specific code. Use this option when only small parts of a component are platform-specific.
When building a cross-platform app, you'll want to re-use as much code as possible. Scenarios may arise where it makes sense for the code to be different, for example you may want to implement separate visual components for iOS and Android.
React Native provides two ways to easily organize your code and separate it by platform:
Platform module.Certain components may have properties that work on one platform only. All of these props are annotated with @platform and have a small badge next to them on the website.
React Native provides a module that detects the platform in which the app is running. You can use the detection logic to implement platform-specific code. Use this option when only small parts of a component are platform-specific.