loading...

React Native Responsive Dimensions - Updated with more responsiveness for foldable devices

dani_akash_ profile image Dani Akash ๐Ÿงช๐Ÿ’ฅ ใƒป2 min read

React Native Responsive Dimensions have been updated to version 3.1.0 with full typescript support & a whole bunch of new utilities quickly check out the new release at github

First published three years ago as a simple utility to resize some views based on the device's screen size, responsive dimensions quickly became one of the favourite tools for my colleagues and many react native developers. I was updating it once a year with a few new things like the responsive hooks last year. But this update is quite important!

I recently worked with Rachel Nabors on React Native Component Docs Drive where while documenting the actual react native's inbuilt dimensions module, I realized Responsive Dimensions has a great potential to simplify application development for foldables and react-native-web apps.

With this new update, Responsive Dimensions now have

  • Separate utilities for Responsive "window" & "screen" sizes (screen sizes will be useful while working with foldables)
  • New responsive screen size hooks
  • useDimensionsChange hook to let your application respond to dimension changes

See the release notes for a full list of changes and also checkout the example projects at Snack & CodeSandbox

Do let me know if you have any feature requests or feedbacks ๏นฃ always happy to help ๐Ÿ˜๐Ÿ‘

Posted on by:

dani_akash_ profile

Dani Akash ๐Ÿงช๐Ÿ’ฅ

@dani_akash_

A React Developer who builds open source libraries for fun. You might actually like them! ๐Ÿ˜‰

Discussion

markdown guide