Skip to content

0.9.0-rc

Pre-release
Pre-release
Compare
Choose a tag to compare
@brentvatne brentvatne released this 01 Aug 01:33

171 commits, 55 contributors.

0.9.0-rc has been published to npm and CocoaPods! There was a short delay for this RC because we wanted to include several breaking changes to Touchable components all at once.

Breaking Changes

  • TouchableX components introduce their own wrapper View: Components like TouchableOpacity and TouchableBounce now use the Animated library to smoothly fade and bounce when touched. A consequence of this is that now we are introducing another View into the hierarchy, because we need to wrap the children in an Animated.View. See the full details and upgrade path here.

We wrote a codemod for fixing many (not all) of the call sites automatically. You can upgrade your code by running the following:

git clone https://github.com/cpojer/js-codemod.git
cd js-codemod/
node_modules/.bin/jscodeshift -t transforms/touchable.js <the folder where your js is>
  • TextInput is now a controlled component: The controlled prop has been removed and TextInput now acts as a controlled component by default. Remove the controlled prop if you were previously using it. (961c1eb). If you were previously using value to set an initial value, now use the initialValue prop instead.

Known Issues

  • Sticky headers do not receive touches: Sticky headers in ListViews don't receive touch events
  • Packager does not support symlinks: Symlinks under node_modules for example are ignored
  • ScrollView sometimes errs with "Cannot find view with tag #XXX": #1941

Deprecations

  • Navigator's onItemRef prop was removed: Use a callback ref directly on the component you return from renderScene instead (4f904b5)

New Features

JavaScript

  • TextInput improvements: TextInput is more reliable and does not drop characters when typing quickly. It also now supports the maxLength prop. (961c1eb)
    rewrite
  • Horizontal ListView: ListViews now check the horizontal prop and calculate layout accordingly (09236cc)
  • Add VerticalUpSwipeJump and VerticalDownSwipeJump to NavigatorSceneConfigs: Check out a demo of it here. (#1822)
  • Text with onPress handlers get highlight: Highlight is the WebKit grey rounded corner background.
    highlight
  • Examples for Image download events in UIExplorer: Check them out here: 74f8055
  • New style properties: perspective, rotateX, rotateY and rotateZ are now available, and a demo of them is available under the Transform example in UIExplorer.
    perspective
  • Add support for files in application home directory: Works as you would expect, application home directory can be referenced with the ~/ prefix. (90dd7a1)
  • Add preventDefault to Navigator events: Gives you more control over your routing (326a66b).
  • tintColor for remote Images: d5943b0
  • Translucent tab bar: Bringing the TabBarIOS api in line with NavigatorIOS, it now supports the translucent prop. (9936a24)
  • Local notification API: PushNotificationIOS now exposes presentLocalNotification and scheduleLocalNotification functions. (a8cb47e)
  • NavigationIOS shadow can be hidden: NavigatorIOS has a new prop called shadowHidden that allows you to hide the hairline shadow (2cb634b)

iOS

  • Add support for gzip of request body: Decoding of response bodies is enabled by default on iOS, this feature will automatically gzip your request body when you to specify the Content-Encoding:gzip header with XMLHttpRequest
  • Use JSONKit if available: If you include JSONKit in your project it will be used by default, which can give a small performance boost in some cases
  • Improvements under the hood to camera roll Images: "Ported over logic where assets are loaded at the optimal size and reloaded if the view size changes" (b34a85f)

Packager

  • More descriptive error messages when a path can't be found: Rather than "Path must be a string. Received null" you will now see "Could not find source file at ..." (70feab9)
  • Chrome debugger automatically reconnects to packager: If the packager is restarted during a Chrome debugging session, the Chrome debugger will automatically reconnect to the packager (fa4c570)

Other

  • The jestSupport folder is published to npm: Provides support files for jest testing

Bug Fixes

  • "RCTImageDownloader was ignoring server response codes. When receiving a response other than 200 it would treat this as success, meaning the image would never load, nor report failure." (d1a82c4)
  • Disable focus on TextInput with editable set to false (5006eca)
  • Set allowsEdgeAntialiasing for transformed views, fixes jagged edges when using the transform property. (see the smooth edges in the transform example above)
  • Fixed crash when app is reloaded while profiling is active
  • Properly free JavaScript executors when app is reloaded (f2d65ea)
  • Pin Babel version to ensure nothing breaks between releases, eg: the spread operator caused some issues in a minor version.