• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

zooniverse/mobile: React native Zooniverse mobile app

原作者: [db:作者] 来自: 网络 收藏 邀请

开源软件名称(OpenSource Name):

zooniverse/mobile

开源软件地址(OpenSource Url):

https://github.com/zooniverse/mobile

开源编程语言(OpenSource Language):

JavaScript 95.8%

开源软件介绍(OpenSource Introduction):

More detailed information on the wiki. In particular, check out our contributor guidelines!

Zooniverse Mobile App

The Zooniverse Mobile app is a React Native app that allows folks like you and me to contribute to astronomy, ecology, and anthropology research from their couch, bathtub, or bus stop (but don't swipe and drive, please).

Setting Up for Local Development

Setting up to work on a react-native app is a little tricky, and setting up to work on this one in particular is trickier. The guide below attempts to be comprehensive. If you run into any further issues while attempting to get set up, please reach out to Chelsea Troy ([email protected])

Preparing The React Native Framework

Requirements:

  • Node >= 6.9.0
  • React Native CLI (npm install -g react-native-cli - may need sudo/admin depending on your setup)

Steps:

  1. Follow the instructions for Android and iOS setup in this guide.
  2. Clone down this repo and navigate to its directory (called mobile).
  3. Run npm install (later, if you need to reinstall dependencies for some reason, you can run rm -rf node_modules/ && npm install)
  4. Run npm start.

Setting up to run on iOS

Requirements:

  • XCode 10.1 or 10.2
  • An iPhone X Simulator, which you can run from XCode.

Steps:

On the command line, from the mobile directory, run:

  1. cd ios && rm -rf Podfile.lock && pod install && cd ... You may need to brew install cocoapods first.
  2. react-native run-ios

iOS Build Troubleshooting:

  • You may need to manually link up the react-native-svg dependency. Open XCode, and in XCode open mobile/ios/ZooniverseMobile.xcworkspace. Follow these instructions to manually link RNSVG.xcodeproj, found at mobile/node_modules/react-native-svg/ios/RNSVG.xcodeproj. For our app, you do need to do step 3 in that tutorial, adding $(SRCROOT)/../node_modules/react-native-svg/ios/RNSVG to our Header Search Paths for both debug and release at Build Settings > Header Search Paths.
  • Switch the project to the XCode Legacy Build System as described here under the section named "Opting out of the new Xcode build system."

Note: There is a bug in Xcode 8 with react-native's RCTWebSocket. If you receive an error, follow the instructions here: http://stackoverflow.com/questions/38710654/rctwebsocket-ignoring-return-value-of-function-declared-with-warn-unused-resul

Android

Requirements:

  • Android Studio (these instructions developed with AS 3.6.3)
  • You'll need at least one emulator. To get one:
    • Within Android Studio, open the "AVD Manager" - in the toolbar click the icon with the purple device and small android (fourth from the right)
    • Click 'Create Virtual Device' - bottom left-hand corner
    • Create at least one using the latest Android Release (Nougat). I have a few different size and Android Release configurations
  • Also you'll need a Gradle properties file outside the project for keeping secrets that aren't checked into source control. This should be in ~/.gradle/gradle.properties and contain the following:
MYAPP_RELEASE_STORE_FILE=/path/to/your/keystore.jks
MYAPP_RELEASE_KEY_ALIAS=android
MYAPP_RELEASE_STORE_PASSWORD=android
MYAPP_RELEASE_KEY_PASSWORD=**you can find this in passbolt**

You will have to get the key itself from an existing maintainer. We are looking for a way to securely store this so you can get it without worrying about corruption. You don't need it to build for debugging—only for release to the Play Store.

Steps:

  1. To run in the emulator from the command line (you'll need device connected or emulator already running): npm run android. Shortly, your emulator should boot with the Zooniverse app on it.
    • You need to have either a device emulator open already or a physical device plugged into your computer. Otherwise, you'll need to run through Android Studio
    • If Android studio prompts you to update Gradle files, you should do it.
    • The command react-native run-android will install the build, but fail in launching the app due to a bug with the react-native script with having a seperate applicationId for development builds.

pullreminders

If you Work for The Zooniverse

You may also want to set up error reporting from your local copy of the application to our reporting service, Sentry. Here are instructions on how to do that!




鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
polinema-mobile/2019-mobile06发布时间:2022-08-30
下一篇:
vum-team/vum: An UI Framework build with Vue.js for mobile webapp发布时间:2022-08-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap