Navigate:
All Reposreact-native-fs
~$REACTN0.0%

react-native-fs: Native filesystem access for React Native

Cross-platform native filesystem operations for React Native applications.

LIVE RANKINGS • 06:50 AM • STEADY
OVERALL
#267
1
MOBILE & DESKTOP
#15
30 DAY RANKING TREND
ovr#267
·Mobil#15
STARS
5.0K
FORKS
1.0K
DOWNLOADS
321.3K
7D STARS
0
7D FORKS
0
See Repo:
Share:

Learn more about react-native-fs

react-native-fs is a React Native module that bridges JavaScript code to native filesystem APIs on multiple platforms. It uses native code implementations for iOS (Objective-C), Android (Java), and Windows to access the underlying operating system's file system capabilities. The library maps platform-specific directory structures and file operations to a unified JavaScript API. Common use cases include downloading files, reading configuration data, caching application content, and managing local file storage within React Native applications.

react-native-fs

1

Multi-platform support

Provides native filesystem access across iOS, Android, and Windows platforms through a single JavaScript API, with platform-specific implementations handling differences in directory structures and permissions.

2

Version compatibility requirements

Maintains specific version branches aligned with React Native and Gradle versions, requiring different installation versions for RN < 0.57, RN 0.57-0.60, and RN >= 0.61 to ensure compatibility with build system changes.

3

Platform-specific directory access

On Android, access is limited to the app's DocumentDirectory (files directory), while iOS and other platforms support broader filesystem access patterns through native bridging.


import RNFS from 'react-native-fs';

const readConfigFile = async () => {
  const path = `${RNFS.DocumentDirectoryPath}/config.txt`;
  const content = await RNFS.readFile(path, 'utf8');
  console.log('File content:', content);
  return content;
};

vv2.20.0

Release notes do not specify breaking changes or requirements; only references PR #1037 for invalidating upload sessions.

  • Review PR #1037 to understand changes to upload session invalidation behavior.
  • Test existing upload workflows to confirm compatibility with session handling updates.
vv2.19.0

Fixes iOS crashes in readDir and corrects stat size type; adds event emitter methods to suppress warnings.

  • Update iOS code to prevent crashes when calling RNFSManager readDir on invalid paths or edge cases.
  • Verify stat size now returns correct numeric type; react-native-windows is now an optional peer dependency.
vv2.18.0

Release notes do not specify breaking changes, new requirements, or feature additions for this version.

  • Review the commit history or changelog file directly to identify actual changes before upgrading.
  • Test file system operations thoroughly in staging as the scope of modifications is undocumented.


[ EXPLORE MORE ]

Related Repositories

Discover similar tools and frameworks used by developers