Home

Awesome

<p align="center"><img src="https://i.imgur.com/Drrulsw.jpg" alt="logo" width="414px"></p>

Osmi Kit Boilerplate

Battle-tested React Native boilerplate

Original concept of this boilerplate is from Ignite. We're really like the project structure from Ignite Boilerplate, especially for Ignite Andross. But we realize that Infinite Red team no longer maintain for the Andross Boilerplate. So, therefore we create an alternative boilerplate like Ignite Andross.

This is the React Native boilerplate that the LibsCode and CloudGakkai team uses on a day-to-day basis to build client apps. Developers who use Osmi Kit report that it saves them two to four weeks of time on average off the beginning of their React Native project!

Tech Stack

Osmi Kit include the following rock-solid technical decisions out of the box:

Quick Start

Prerequisites:

Install Global CLI:

// npm
npm install -g osmi-cli

// yarn
yarn global add osmi-cli

Run the CLI:

osmi new MyApp

And Osmi will walk you through the rest.

Boilerplate walkthrough

Your App folder is where most of the goodies are found in an Osmi Kit app. Let's walk through them in more detail. Start with Containers/App.js (described below) and work your way down the walkthrough in order.

Containers

Containers are (mostly) full screens, although they can be sections of screens or application containers.

To generate a new Container or Screen you can use the following generator commands:

Navigation

Your primary and other navigation components reside here.

Components

React components go here...pretty self-explanatory. We won't go through each in detail -- open each file to read the comments and view the code.

To generate a new Component you can use the following generator commands:

Themes

Styling themes used throughout your app styles. Since we're using OsmiCSX for the styling framework, OsmiProvider and CustomTheme goes here.

Config

Initialize and configure things here.

Fixtures

Contains json files that mimic API responses for quicker development. These are used by the Services/FixtureApi.js object to mock API responses.

Redux, Sagas

Contains a preconfigured Redux and Redux-Sagas setup. Review each file carefully to see how Redux interacts with your application.

Here again we have generators to help you out. You just have to use one of the following:

Services

Contains your API service and other important utilities for your application.

Lib

We recommend using this folder for modules that can be extracted into their own NPM packages at some point.

Images

Contains actual images (usually png) used in your application.

Tests

This folder (located as a sibling to App) contains sample Jest snapshot and unit tests for your application.

Troubleshooting

If you found that the boilerplate is not installer properly on your React Native proect app. Usually it's because you already install the react-native-cli globally, to solve this try to run :

npm uninstall -g react-native-cli
// or
yarn global remove react-native-cli

Special Thanks

Special thanks to Infinite Red who create such as beautiful react-native boilerplate (Ignite CLI). And give the inspiration for me to create this alternative cli and boilerplate.