- Remove deprecated Slider, DatePickerIOS & ProgressViewIOS 82dc6e1 by @MoOx
- Add VirtualizedList
onStartReached
/onStartReachedThreshold
props d69aa1e by @MoOx - Add Appearance
setColorScheme
method 878f426 by @MoOx - Add Style
borderBlockColor
borderBlockEndColor
`borderBlockStartCo… a12bade by @MoOx - Add Style
borderEndEndRadius``borderEndStartRadius
`borderStartEndRadi… 66b5cbd by @MoOx - Add Style margin & padding CSS logical props c91f345 by @MoOx
- Add various Android accessibility roles values 7057d79 by @MoOx
Remove package.json
engine
section to avoid Yarn installation issue.
This release requires @rescript/react 0.11.0 or later. It contains various breaking changes to match React Native 0.71.
You can see changelog by comparing 0.71 to 0.70
This release requires ReScript 10.0.0 or later. It contains various breaking changes.
_end
is nowend
(not a reserved word anymore) 92e3c6f by @cknitt- Camel cased polymorphic variants &
_
prefixed props when possible have been changed to reflect React Native original naming convention. Things like#plainText
,#boxNone
etc have been changed to what they should be (#"plain-text"
,#"box-none"
etc) 6495093 & 6495093 by @cknitt & 4360933 by @MoOx - Because a limitation with ReScript that doesn't handle correctly numeric string as polymorphic variant,
fontWeight
is now an abstract type. This means thatstyle(~fontWeight=#_600, ())
now becomesstyle(~fontWeight=FontWeight._600, ())
44885db by @cknitt @string
usage have been removed when possible. This means types that were inlined in bindings are now common. 6495093 by @cknittPlatform.os
now use polymorphic variant.if Platform.os === Platform.android
becomesif Platform.os === #android
. Be careful: if used in a switch, you will lose metro bundler optimisation ! b189fbc & 9964b13 by @cknittPlatformColor
have been rewritten. Lots of deprecation & polymorphic variants changes (eg: for android, instead of#background_dark
use#"@android:color/background_dark"
) 036566e by @MoOxAppearance
now returnsoption<t>
instead ofJs.Null.t<t>
thanks to@nullable
91f0a67 by @cknitt- Deprecated
Style.pt
unit as been removed (usedp
instead (density pixel)) 3df0fcf by @cknitt
- Most object types created using externals can now be created using objects with optional fields. This means that things like
ActionSheetIOS.showActionSheetWithOptions(ActionSheetIOS.shareOptions(~url,(), /*...*/)
can be writtenActionSheetIOS.showActionSheetWithOptions({url}, /*...*/)
. Previous@obj
external helpers will be deprecated in the future, and then removed. Note thatStyle.style()
now have a replacementStyle.s()
that accepts an object with optional keys ! e606a03 by @cknitt - Lots of
[email protected]
View props have been added bee39e5 by @MoOx - Added
Style.empty
to avoidStyle.arrayOption
(so you can write things likeStyle.array([style1, condition ? style2 : Style.empty])
) 762049d by @cknitt
- Update
PushNotificationIOS.checkPermissions
to include iOS 10+ notification settings 14212c0 by @MoOx
- Add
dismissActionSheet
method toActionSheetIOS
7e42b63 by @MoOx - Add
accessibilityLanguage
prop to all the available components a210356 by @MoOx - Add
soundName
option for local push notifications inPushNotificationIOS
4f04d77 by @MoOx - Create
HitSlop
&Rect
module (don't use them directly yet, wait for 0.70 release...) 394bd60 by @MoOx
- Add
Animated.Color
node a761012 by @MoOx - Add option to supply
platformConfig
to NativeAnimated ff931ea by @MoOx - Add
TextInput
setSelection
method 32c12da by @MoOx - Add
accessibilityLabelledBy
Android View prop 35306c3 by @MoOx - Add
AccessibilityInfo.isAccessibilityServiceEnabled
4fb9319 by @MoOx
This changes are just to follow React Native 0.67 changes.
- Add
ACCESS_MEDIA_LOCATION
permission to PermisionsAndroid library 5338327 by @MoOx - Added
cancelButtonTintColor
prop forActionSheetIOS
to change only the text color of the cancel button 42dd7ee by @MoOx - Add missing
Keyboard.removeListener
05a5656 by @MoOx - Remove
#high
and#balanced
as values forandroid_hyphenationFrequency
onText
d73c6d7 by @MoOx - Remove
DatePickerAndroid
31549b1 by @MoOx
- Remove Picker & PickerIOS (Use https://github.com/react-native-picker/picker & https://github.com/rescript-react-native/picker instead) 9e45fcd by @MoOx
- Update
TextInput
autoCompleteType
prop toautoComplete
ee307e6 by @MoOx - Change
TextInput
autoComplete
prop values (add more & change some to quoted polymorphic variants)) 21e802d by @MoOx
- Add
#togglebutton
toaccessibilityRole
prop 0b4688b by @MoOx - Add
accessibilityRole
#tabbar
value 7c8f283 by @MoOx - Add
Button
accessible
,accessibilityActions
&onAccessibilityAction
props 484e344 by @MoOx - Add
PermissionsAndroid
bluetoothAdvertise
permission e1ca5e5 by @MoOx - Add
PlatformColor
iOS missing standard colors 92e7d77 by @MoOx - Add
Pressable
foreground
option for ripple config for Android 9bd7499 by @MoOx - Add
Text
accessibilityActions
&onAccessibilityActions
props 9b52e53 by @MoOx
rescript
package is now replacingbs-platform
.- Several
removeEventListener
calls were removed or deprecated in React Native 0.65. You might have to update your code to reflect this. Check the full list below (or just follow compilation warnings/errors).
- Use
rescript@^9.1.4
instead ofbs-platform@
as a peerDependency a2ae907 by @MoOx - Replace
EventSubscription.t
so you can call.remove()
onEventSubscription.t
instead of->EventSubscription.remove()
71399ce by @MoOx - Remove
NativeEventEmitter.removeSubscription
in favor ofremove()
on subscription itself df060f9 by @MoOx - Remove
Keyboard
removeAllListeners
andremoveListener
(you should useremove
on listener itself) 2091cb3 by @MoOx - Remove
AppState.removeEventListener
. Instead, use theremove()
method on the listener itself 84284e8 by @MoOx - Remove
NativeEventEmitter.Subscription
in favor of just calling.remove()
method on listeners. 0e4bb2d by @MoOx - Change
Dimensions.addEventListener
(now returns anEventSubscription.t
so you can callremove()
on listener directly ) 1131382 by @MoOx
- Deprecate
AccessibilityInfo.removeEventListener
in favor ofremove
method on the listener itself 44f4465 by @MoOx - Deprecate
EventEmitter#removeSubscription
in favor ofremove()
on subscription itself a771dc8 by @MoOx - Deprecate
Linking.removeEventListener
. Instead, callremove()
on the listener itself 4b98e2b by @MoOx
- Add
AccessibilityInfo.getRecommendedTimeoutMillis
a90fe94 by @MoOx - Add
Appearance.addChangeListener
2cda177 by @MoOx - Add
Button
accessibilityState
prop 7573c50 by @MoOx - Add
Color.processColor
method 0c880f8 by @MoOx - Add
DynamicColorIOS
highContrastLight
&highContrastDark
optional values (with newDynamicColorIOS.dynamicColor()
since they are optional) cc4132b by @MoOx - Add
Pressable
onBlur
andonFocus
props 575a634 by @MoOx - Add
Pressable
onHoverIn
andonHoverOut
react-native-web 0.16 props e625be2 by @jfrolich - Add
Pressable
unstable_pressDelay
prop 3d3bf2b & 0117e3e by @jfrolich - Add
PushNotificationIOS.getAuthorizationStatus
method ffc2f0c by @MoOx - Add
RefreshControl
size
option 5678d16 by @MoOx - Add
stickyHeaderHiddenOnScroll
props toScrollView
& friends d981203 by @MoOx - Add
Text
onPressIn
&onPressOut
props 536ea0e by @MoOx - Add
TouchableHighlight
&TouchableOpacity
react-native-web 0.16 View prop fbf9571 by @jfrolich
🚨 Minor Breaking changes for React Native Web users only
- Remove
rel
&target
View props - Add React Native Web
hrefAttrs
prop for 0.16
Ooopsy. Actually this release contains .res/.resi files.
reason-react-native
->rescript-react-native
peerDependencies
changed to"@rescript/react": "^0.10.0"
"bs-platform": "^9.0.0"
- Removed
CheckBox
76ef45c by @MoOx ImageLoadEvent.source.url
is nowImageLoadEvent.source.uri
ce21b74 by @MoOx- Remove
UIManager.playTouchSound
(useSoundManager.playTouchSound
instead) cd03cfb by @MoOx Pressable_
is nowPressable
(to benefit of the full benefit of Pressable, following deprecation notice in 0.63.3) 421962f by @MoOx- Changed
ActionSheetIOS
destructiveButtonIndex
to accept array instead of just int (as RN acceptsint | array<int>
) 81f4f18 by @MoOx - Changed
Image
uriSource
headers
to beJs.Dict.t(string)
ca786f9 by @MoOx
- Added
PlatformColor
iOSclear
color b813ee9 by @MoOx + b9e33c7 - Added
Text
android_hyphenationFrequency
prop 1864063 by @MoOx - Added
Text
dataDetectorTypes
prop 635066c by @MoOx - Added
Text
disabled
prop 635066c by @MoOx - Added
Text
maxFontSize…Multiplier
prop 635066c by @MoOx - Added
Text
nativeID
prop 635066c by @MoOx - Added
Text
onTextLayout
prop 635066c by @MoOx - Added
Text
gesture responder props 635066c by @MoOx - Added
TextInput
onPressIn
&onPressOut
13b8e7f by @MoOx - Added
NativeEventEmitter.listenerCount
e88e336 by @MoOx - Added
ActionSheetIOS
disabledButtonIndices
74af1ab by @MoOx
Fix & change Android PlatformColor binding to use built-in selector #737 by @diaozheng999
- Fixed
PlatformColor.Android.getAttr
: now use"?android:attr/*
instead of"?attr/*
- Added
PlatformColor.Android.get{x}
(x being an integer from 2 to 7) so you can use@android:color
&@?android:attr
in the same call, asPlatformColor
accepts multiple arguments as fallbacks. - Added
PlatformColor.unsafeGet{x}
(x being an integer from 2 to 7) that allow you to pass unsafe values (string, which can be useful for user defined values).
Also:
- Added
PlatformColor.Android.get
- Added
PlatformColor.Ios.get{x}
like Android PlatformColor.IOS
is deprecated in favor ofPlatformColor.Ios
PlatformColor.Android.unsafeGet
is deprecated in favor ofPlatformColor.unsafeGet
Fixed measure
& measureInWindow
functions types #736 by @Freddy03h
Added Pressable with child function and interaction states (as Pressable_
) #735 by @Freddy03h
Breaking change, sorry: Reverting ActivityIndicator size as polymorphic variant so we can keep the exact option.
Fix npm description
⚠️ Changed minimal versions required #722 by @cknitt- ReScript / bs-platform 8.2
- rescript-react 0.9.1
- Switched solution to avoid warnings being throw as errors b5038e9 by @MoOx with the help of @Freddy03h and @bobzhang in #718 This will help to avoid issue if ReScript introduce new warning that caused in the past impossibility to use our bindings (eg: ReScript 8.2 bs.string annontations).
- Switch to polymorphic variants instead of abstract types where possible #724 #727 by @cknitt
- Removed superfluous bs.string attributes #723 by @cknitt This change shouldn't impact your code if you are using ReScript 8.2 as required.
- Accessibility changes for react-native 0.63 #728 by @cknitt
- Removed
accessibilityComponentType
- Removed
accessibilityTraits
. - Added
AccessibilityActionEvent
- Added
onAccessibilityAction
. - Added
Accessibility.actionInfo
(already there, but broken - missing unit to terminate argument list). - Note that
Accessibility.role
was actually already up to date (except for the value "switch" which we can't add because it's a keyword). Feel free to open an issue if you needswitch
value.
- Removed
- Removed
Global.unstable_enableLogBox
#718 by @gedeagas This is now enabled by default in React Native 0.63. See addedLogBox
bindings for more options. - Removed
tintColor
prop from Switch component #714 by @gedeagas
- Added
DynamicColorIOS
#717 by @celsobonutti Note that there is only 2 keys (light
anddark
) but React Native documentation mention they might be more in the future, without saying if they will be mandatory or not. If you want to protect yourself, you might want to make your own factory. In any case, we can still deprecate themake
binding & create a new external binding with optional keys. So don't worry too much. - Added
PlatformColor
binding #730 by @rifaldhiaw - Added
PermissionsAndroid.accessBackgroundLocation
#729 by @cknitt + b8392e3 by @MoOx - Added
LogBox
#711 by @idkjs - Added
accessibilityActions
prop #713 by @gedeagas - Added
Pressable
#712 by @gedeagas - Added
AppState
valuesunknown
andextension
(iOS) #726 by @cknitt
- ReScript branding has been adopted in various places in all the repos of our organisation.
- More futur proof "files" patterns for npm (in case of interop files) 1a3b677 by @MoOx
- Simplify package.json files section a9cacbd by @MoOx
- Stop blocking compilation because of ReScript warnings (emitted as errors) #708 by @jfrolich
This is to ensure ReScript 8.2 compatibility & avoid similar problem in the future.
- Fixed View props for all components that use them (stay in sync) e5adee0 by @MoOx
- Removed TabBarIOS (removed since RN 0.59) 13991e0 by @MoOx
- Internal: removed duplicated code source in md files (website will produce the same result - no manual syncing required) 1524b87 by @MoOx
The release we all have been waiting for (thanks for you patience)!
Huge thanks to @sgny which handled most of the
changes directly related to react-native 0.62.
tl;dr: this release includes
- breaking changes related to
[email protected]
- breaking changes related to
bs-platform@7
(say bye to most##
accessors in favor of.
) - breaking changes related to
[email protected]
(say bye to removed components)
So in order to upgrade to this release you need to upgrade all this dependencies
at the same time. Be sure to respect
peerDependencies
before reporting issue.
- Upgraded rescript-react to 0.8.0 (#689) by @jfrolich
See https://rescript-lang.org/blog/rescript-react-0-8-0 for more informations - Upgraded to bs-platform 7.3.0 (#631) by @idkjs (#666) by @Arnarkari93 (#674) (#693) (#690) (#694) by @sgny (#695) by @cknitt
We have convertedJs.t
objects to records where possible (we had to skipped objects that rely on[@bs.meth]
). This means ou will have to change a lot of##
notation to just a dot (.
) to access properties.
See https://rescript-lang.org/blog/whats-new-in-7-pt1 for more informations - Removed some methods for FlatList, ScrollView, SectionList, VirtualizedList and VirtualizedSectionList (#680) by @sgny
These components are interrelated in the sense of being based on each other and inheriting props, however, applicable methods are not inherited quite so consistently. We removed unavailable methods from each component. - Removed
accessibilityStates
prop (#656) by @sgny - Removed
TextInput
onTextInput
andselectionState
props (#658) by @sgny - Animated: setting
useNativeDriver
prop is required (#655) by @sgny - Handle deprecated or removed components and APIs (#668) by @sgny
- Removed components:
ToolbarAndroid
,ViewPagerAndroid
,WebView
- Removed APIs:
AlertIOS
,CameraRoll
,GeoLocation
,ImageEditor
,NetInfo
,TimePickerAndroid
- Some others components that have been deprecated in RN regarding "Lean Core" initiative have been documented as such and will be removed in future releases.
- Removed components:
- Deprecated
Style.list
&Style.listOption
for future bs-platform 8.0.0 compatibility (#700) by @MoOx
- Fixed
DatePickerIOS
minuteInterval
type (int, not string) (#648) by @idkjs - Fixed
Animated.ValueXY.getTranslateTransform(value)
binding (#675) by @benadamstyles - Fixed
Global.hermesInternal
(#703) by @fa7ad - Fixed
TouchableNativeFeedback.Background.canUseNativeForeground
type (#704) by @phamhoaivu911
- Added support for callback refs (#684) by @cknitt
- Added
unstable_enableLogBox
(#692) by @MoOx - Added
Appearance
module (#654) (#662) (#677) by @sgny - Added Modal
statusBarTranslucent
prop (#660) by @sgny - Added missing accessibility props to
Touchable*
components (#659) by @sgny - Added
accessibilityState
prop and constructor for related object (#657) by @sgny - Added
DevSettings
module (#661) (#664) by @sgny - Added
fadingEdgeLength
prop to FlatList, ScrollView, SectionList etc (#663) by @sgny - Added
accessibilityValue
prop (#665) - Added mouse event for
react-native-web
(#646) by @Naturalclar - Added
onMouseEnter
,onMouseLeave
props for View, Text, TextInput and more web props, press-event, href and target (#650) by @jfrolich - Updated Linking documentation (#673) by @sgny
- Updated Event documentation (#672) by @sgny
- Add
NativeEventEmitter
#642 by @cknitt - New abstract type for Android Date/TimePicker
action
#640 by @cknitt - Add
accessibilityRole
web values andarialLevel
web props (#639 by @Naturalclar
- Fix
autoCompleteType
prop forTextInput
component (previously incorrectly namedautoComplete
) (#639 by @Naturalclar - Resolves all ReScript / BuckleScript inferred name warnings (#628 by @idkjs
- Change type for
DrawerLayoutAndroid
drawerPosition
prop #626 by @sgny.
You need to replaceDrawerLayoutAndroid.left
&DrawerLayoutAndroid.right
by [](https://github.com/`) ` left
&`right
.
- Add
SoundManager
+ deprecateUIManager.playTouchSound
#616 by @sgny - Add
useWindowDimensions
hook #615 by @sgny - Add
touchSoundDisabled
prop toButton
and all Touchable components #627 by @stuartkeith
Probably the latest release for React Native 0.60. We will focus on 0.61.
Sorry, a mix of bugfixes & changes! This should be easy to handle for you.
- Add constructor for section type in
VirtualizedSectionList
#614 by @sgny - Add
SectionList
/VirtualizedSectionList
section data as parameterized type #618 by @jfrolich
- Fix
AppState
(now returnunit
) #568 by @cknitt - Fix
Animated.event
type so it can be used inAnimated.ScrollView
onScroll
props (& similar) #584 by @MoOx - Fix missing
[@bs.meth]
in methods ofEvent
,BackHandler
&NetInfo
#621 by @cknitt - Fix
ScrollView
scrollToItem
,scrollToIndex
andscrollToOffset
#569 by @benadamstyles - Fix
Webview
contentInset
prop #607 by @cem2ran - Fix
WebView
event types & add missing fields #608 by @cem2ran
- Add
AccessibilityInfo
#587 by @sgny - Add
Alert.prompt
#617 by by @fhammerschmidt - Add
Animated.SectionList
andAnimated.FlatList
#600 by @sgny + #623 by @jfrolich - Add lots of
AppRegistry
methods #567 by @sgny + #560 by @cknitt - Add
Global.__DEV__
#609 by @sgny - Add
Global.hermesInternal
#613 by @MoOx - Add
YellowBox
#562 by @cknitt
We improved some part of the missing docs, thanks to contributions of @sgny,
@idkjs, @fhammerschmidt & @MoOx and maybe others we forgot to mention (but
git log
doesn't)
✨ Initial release for this new React Native bindings!
See https://rescript-react-native.github.io/en/blog/2019-06-17-hello-reason-react-native/ for more information.