GithubHelp home page GithubHelp logo

discipletoolsbot / disciple-tools-mobile-app Goto Github PK

View Code? Open in Web Editor NEW

This project forked from discipletools/disciple-tools-mobile-app

0.0 0.0 0.0 17.56 MB

The React Native code base for the Disciple.Tools mobile app

Home Page: https://disciple.tools/

Shell 0.01% JavaScript 99.37% TypeScript 0.61%

disciple-tools-mobile-app's Introduction

Disciple Tools Mobile App

The React Native code base for the Disciple Tools mobile app.

Download the App

AppStore PlayStore

Latest status

Production Development

Team

Dependent Repo

Offline Usage

Offline Usage Guide

Basic Design Idea

Basic Design Idea

Installation (Development)

npm install
npm start
OR
expo start
  • Run in Simulator:

  • Run on device (phone) via Expo:

    • Scan the QR code above with Expo Go (Android) or the Camera app (iOS), or
    • or, manually open Expo app on phone and select appropriate option from under "Development servers"
    • (NOTE: Your phone must be on the same local network as the development computer)
    • To run on the phone you will first need to patch the diff with npm run patch:List
    • Before committing make sure to unpatch using npm run unpatch:List
  • Recently tested with the following library versions:

    • Node v14 or v16 (or should work with latest)
    • Expo CLI v5+

Issues

HTTPS

You MUST connect to a D.T. instance URL with https protocol, otherwise it will fail to connect with

"Network Error"

If you are using a local D.T. instance without SSL, you can use a service like ngrok or cloudflared to create a tunnel to an https address.

With this solution, you would then also need to change the values of home and siteurl in the dt_options table in your WP database.

Firewall

If running on a device using Expo, you may need to open the necessary port on your computer to allow expo to access the app.

DataStore

Information on the redux setup for managing data: Data Store

Tests

Run all tests:

npm run test

Design Decisions

General:

  • Offline-First (via dispatch to Redux onAppBackground & persistent FIFO request queue for API writes)
  • Aggressive data fetching, preferring to get all vs. pagination (so that data is available offline)
  • CNonce: PIN (3 sec)
  • (Coming soon) Accessibility (double as Test IDs?)

UI/Framework-specific:

  • Functional Components vs. Class
  • Modular component design to mirror D.T Post Types and Fields, and dynamically respond to API changes, and support plugins
  • Custom Hooks - map well to REST endpoints
  • SWR (stale-while-revalidate), also meets requirement for background fetching, onFocus fetching (prevent stale data on refocus of app)
  • Redux AND Context - Redux handles any persisted state, and Context is in-memory, runtime app state
  • Prefer Skeletons to Spinners, except for Button Actions
  • Minimize 3rd party dependencies where possible (eg, implement own Login form validation vs. something like Formik). Purpose: long-term maintenance (since this is an OSS project with volunteers), fewer library preference debates, less app bloat
  • SecureStore - use as much as practical
  • Component Library: N/A (removed Native Base)
  • Abstract service libraries (ie, Expo, SWR, Axios) via Hooks, in case we want to swap for something else later

Contributing

Contributing Guide

disciple-tools-mobile-app's People

Contributors

zdmc23 avatar raschdiaz avatar mikeallbutt avatar cairocoder01 avatar jayabrown avatar shady-hakim avatar jl0325 avatar dependabot[bot] avatar steven-shubham avatar chrischasm avatar jhenterprise avatar maxwelldg avatar micahmills avatar squigglybob avatar corsacca avatar yorkaspacher avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.