react-native-recoil-flipper-client
TypeScript icon, indicating that this package has built-in type declarations

0.0.4-alpha.0 • Public • Published

react-native-recoil-flipper-client

Important Notes

  • This state provider client requires that the flipper-plugin-react-native-recoil plugin be installed within your desktop Flipper client application in order to work.
  • State reporting functionality may be relying on experimental or unstable Recoil hooks.

Requires

  • React Native
  • Recoil

Installation

Make sure you NPM install react-native-flipper in addition to this client. (e.g. npm i --save react-native-recoil-flipper-client react-native-flipper). Although Flipper support is enabled in React Native by default, the functionality provided by react-native-flipper is not.

Usage

Add this client to your React Native project by mounting it within your App JSX tree anywhere, but ideally immediately inside RecoilRoot.

To mount the client, you'll want to import the client (1) and use the JSX tag as follows:

import React from 'react';
import { RecoilRoot } from 'recoil';
import { RootRouter } from './route';
import { RecoilFlipperClient } from 'react-native-recoil-flipper-client'; (1)

function App() {
    return (
        <RecoilRoot>
            <RecoilFlipperClient /> (2)
            <RootRouter />
        </RecoilRoot>
    );
}

export default App;

Where RootRouter is your main App's entry point.

Development

...

Todo

  • [ ] add supported Recoil version to README requires section

Package Sidebar

Install

npm i react-native-recoil-flipper-client

Weekly Downloads

10

Version

0.0.4-alpha.0

License

MIT

Unpacked Size

5.51 kB

Total Files

5

Last publish

Collaborators

  • kolohelios