React Native integration with FrintJS
Switch branches/tags
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.editorconfig
.eslintrc
.gitignore
.travis.yml
LICENSE
Makefile
README.md
index.js
package.json

README.md

frint-react-native npm Build Status License

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