frint-react-native [](https://www.npmjs.com/package/frint-react-native) [](https://travis-ci.org/frintjs/frint-react-native) [](https://github.com/frintjs/frint-react-native/blob/master/LICENSE)

October 17, 2017 ยท View on GitHub

React Native integration for FrintJS.

Install

You should already have these FrintJS dependencies first:

$ npm install --save frint frint-react

Now you can install the package for React Native integration:

$ npm install --save frint-react-native

Usage

You can write a regular FrintJS application with React first:

// App.js
import { createApp } from 'frint';
import React from 'react';
import { View, Text } from 'react-native';

function Root() {
  return (
    <View>
      <Text>Hello World!</Text>
    </View>
  );
}

const App = createApp({
  name: 'MyReactNativeProject',
  providers: [
    {
      name: 'component',
      useValue: Root,
    },
  ],
});

export default App;

Now instantiate and register it to React Native:

// index.js
import { register } from 'frint-react-native';

import App from './App';

const app = new App();
register(app);

License

MIT