Qribto – React Native Full App Docs


All the features you will love

  • WordPress Integration via REST API
  • Integration via CoinCap.io
  • OneSignal Notification
  • RTL
  • Multi Languages
  • Offline Mode Reading
  • Sidebar with multi-level Menu
  • Your page template
  • Infinite Lazy load
  • Social Shareing feature
  • Contact page
  • Clean code, no bullshit!
  • Best UI/UX Practices

Website & Video:

Supporting websitehttps://support.reactaz.com/qribto-react-native-full-app-docs//

Installing video: https://youtu.be/KqWynRHhAVQ

Qribto 1.x – React Native app for WordPress

2.Set Up

2.1.How to install a new source

In order to setup for React Native (RN) template you should connect to the internet and install dependencies library. If you have not chanced to set it up with React Native, please take a look to the document here: https://facebook.github.io/react-native/docs/getting-started.html

Step 1:  Installing

  • Unzip the downloaded code from Code Canyon.
  • Using the terminal, issue the following command.

npm install
This will install all the required modules for your app.

Step 2: Linking Libraries

Link your native dependencies:

$ react-native link

Done! All libraries with a native dependencies should be successfully linked to your iOS/Android project.

Step 3: Starting the server.

  • To simulate for iOS
    • Method One:
      • Open the project in XCode from ios/[yourProject].xcodeproj
      • Hit button to simulate.
    • Method Two: 
      • In your terminal, type:
        react-native run-ios
  • To simulate for Android
    • Make sure you have an Android emulator installed and running.
    • In your terminal, type:
      react-native run-android


2.2.Video Tutorial

Let’s see quick installing guide in the following video:

  • 00:13 Install node_modules
  • 01:05 Linking Libraries
  • 04:01 Running app on IOS
  • 06:37 Running app on Android

3.Project structure

The Qribto project files/folders inside this main-folder …src*:

  • app.js: Everything is started from here.
  • corebase/settings/global.js: Include all settings for Qribto, used at config domain wordpress site, menu etc…
  • themes: All components in this app depend on the application theme.
  • containers: These screens are essentially “smart” container component that handle all of the data fetching, interaction management, etc. 
  • corebase/components: In this directory we’ll be writing mostly functional components that can be used in multiple places throughout our app.
  • corebase/services/wordpress.service.js: A service for fetching data from WordPress.
  • corebase/services/helper.service.js: A helping-service, it includes any helpful-functions such as: isEmail (validate email), displayDateWordpress (show date by predefined-date-format from a complicated-date-string), LaunchURL (open an url refer to app),…

4.Wordpress integration via Rest API

4.1.Install Wordpress plugins

Just install UWD plugin in your package or from  https://wordpress.org/plugins/ultimate-wp-rest/

4.2.Config Wordpress "domain"

Step 1: Go to: …src/corebase/settings/global.js
Step 2: Find out key “domain” Global>INTEGRATE>wordpress>domain, change yours, Ex: demo.gikapp.com

5.Config Theme

5.1.Config "Menu"

Step 1: Go to your theme: …src/themes[your_theme]/common/Config.js
Step 2: Change param to yours, Ex: 17


Go to your theme: /src/themes/[your_theme]/common/config.js

Find out key HOMEPAGES_CONFIG>widgets, need to update widgets data by changing:

We have 20+ Excellent Code Snippet :

  • swipper_carousel
  • banner_carousel with 5 item styles
  • list_item_widget with 4 item styles
  • wordpress_article_list with 10 item styles
  • testimonials_widget
  • list_image_widget

5.2.3.Config list_item_widget

Insert bellow code intro widgets: []

With app_action field, you have 3 action types:

  • blog: redirect to Blog Screen with blogID is defined by value field
    • layout_children: Apply one of 10+ post layout styles (“TwoColumn” || “ThreeColumn” || “Card” || “CardType2” || “Portfolio” || “PortfolioType2” || “PortfolioType3” || “List” || “ListType2” || “Backdrop”)
  • article: redirect to Article Detail Screen with aritcleID is defined by value field
  • page: redirect to Page Detail Screen with pageID is defined by value field

With layout field, you have 4 options:

5.2.4.Config wordpress_article_list widget

Insert bellow code intro widgets: []

With layout field, you have 10+ options:

Apply one of 10+ post layout styles (“TwoColumn” || “ThreeColumn” || “Card” || “CardType2” || “Portfolio” || “PortfolioType2” || “PortfolioType3” || “List” || “ListType2” || “Backdrop”)

5.2.5.Config Latest Post widget

Insert below code intro widgets: []

6.How to use

6.1.Change Splash Sceen

Go to your theme: /src/themes/[your_theme]/images/

Replace splash.jpg

6.2.Config Google Admob

Step 1: To enable / disable Google Admob, go to: ../src/corebase/settings/global.js

Step 2: Go to ../src/themes/[your_theme]/screens/HomeScreen.js then change your Admob ID

6.3.Configurate Push Notification

  1. You need to setup OneSignal account to support pushnotification (https://onesignal.com)
  2. Install WordPress plugin to support push notification after publish a post: https://wordpress.org/plugins/onesignal-free-web-push-notifications/

  3. The download package has already configure all the setting for you, but you need to replace the APP_ID to integrate with your OneSignal account. You can also refer detail document here for setting up – https://github.com/geektimecoil/react-native-onesignal

6.4.Multi Languages & RTL

You can add your own language to the app from src/corebase/i18n/locate/[your location].js

In src/corebase/i18n/index.js, export configuration (for translations):

For more info about I18n.js methods (localize, pluralize, etc) and settings see its documentation.

The language to Right to Left support:
Go to */src/corebase/settings/global.js, change the config RTL=true like the screenshot.

6.6.Creating and Using a Custom Icon Font for Android

This method has the advantage of fonts being copied from this module at build time so that the fonts and JS are always in sync, making upgrades painless.

Edit android/app/build.gradle ( NOT android/build.gradle ) and add the following:

apply from: "../../node_modules/react-native-vector-icons/fonts.gradle"
To customize the files being copied, add the following instead:

project.ext.vectoricons = [
iconFontNames: [ 'MaterialIcons.ttf', 'EvilIcons.ttf' ] // Name of the font files you want to copy

apply from: “../../node_modules/react-native-vector-icons/fonts.gradle”

Option: Manually

Copy the contents in the Fonts folder to android/app/src/main/assets/fonts (note lowercase font folder).
Integrating library for getImageSource and ToolbarAndroid support

These steps are optional and only needed if you want to use the Icon.getImageSource function or using custom icons in the Icon.ToolbarAndroid component.

Edit android/settings.gradle to look like this (without the +):

rootProject.name = 'MyApp'
include ':app'
+ include ':react-native-vector-icons'
+ project(':react-native-vector-icons').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-vector-icons/android')

Edit android/app/build.gradle (note: app folder) to look like this (without the +):

apply plugin: 'com.android.application'
android {
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile "com.android.support:appcompat-v7:23.0.1"
compile "com.facebook.react:react-native:+" // From node_modules
+ compile project(':react-native-vector-icons')

Edit your MainApplication.java (deep in android/app/src/main/java/...) to look like this (note two places to edit )(without the +):

package com.myapp;
+ import com.oblador.vectoricons.VectorIconsPackage;
protected List<ReactPackage> getPackages() {
return Arrays.<ReactPackage>asList(
new MainReactPackage()
+ , new VectorIconsPackage()

Note: If you’re using React Native (Android) <= 0.17, follow this instructions

Option: With rnpm

$ react-native link

Note: Some users are having trouble using this method, try one of the others if you are too.

To config for IOS, see more: https://support.reactaz.com/knowledge-base/creating-and-using-a-custom-icon-font/

Source: https://github.com/oblador/react-native-vector-icons

6.7.Creating and Using a Custom Icon Font for IOS

Option: Manually

If you want to use any of the bundled icons, you need to add the icon fonts to your Xcode project. Just follow these steps:

Browse to node_modules/react-native-vector-icons and drag the folder Fonts (or just the ones you want) to your project in Xcode. Make sure your app is checked under “Add to targets” and that “Create groups” is checked if you add the whole folder.

Edit Info.plist and add a property called Fonts provided by application (or UIAppFonts if Xcode won’t autocomplete/not using Xcode) and type in the files you just added. It will look something like this:
XCode screenshot

Note: you need to recompile your project after adding new fonts, also ensure that they also appear under Copy Bundle Resources in Build Phases.

If you want to use the TabBar/NavigatorIOS integration or use getImageSource, then you need to add RNVectorIcons.xcodeproj to Libraries and add libRNVectorIcons.a to Link Binary With Libraries under Build Phases. More info and screenshots about how to do this is available in the React Native documentation.

Option: With CocoaPods

Add the following to your Podfile and run pod update:

pod 'RNVectorIcons', :path => 'node_modules/react-native-vector-icons'

Edit Info.plist as described above.

Option: With rnpm

$ react-native link

Note: Some users are having trouble using this method, try one of the others if you are too.

To configure for Android, see more: https://support.reactaz.com/knowledge-base/creating-and-using-a-custom-icon-font-for-android/

Suggest Edit

Leave A Comment?