• Stars
    star
    253
  • Rank 160,776 (Top 4 %)
  • Language
    TypeScript
  • License
    Apache License 2.0
  • Created about 3 years ago
  • Updated 10 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

The Taro Playground App is a cross-platform application developed using Taro, to help developers develop and debug Taro applications.

Taro Playground App

The Taro Playground App is a cross-platform application developed using Taro, to help developers develop and debug Taro applications. It is initialized using taro react native template.

Preview

Android iOS Web Mini Program
https://github.com/wuba/taro-playground/releases https://apps.apple.com/cn/app/taro-playground/id1576830673 https://wuba.github.io/taro-playground/ https://github.com/wuba/taro-playground

https://testflight.apple.com/join/RDFCp2yy

Supported versions

  1. taro: @tarojs/cli@^3.2.0
  2. framework: 'react'
Playground Version Taro version React Native version branch
1.1.2 >= 3.2.0, < 3.3.10 0.64 releases/rn-0.64+taro-3.3.9
1.2.0 ~ 1.3.9 >= 3.3.10, < 3.4.2 0.66 releases/rn-0.66+taro-3.4.2
1.4.0 ~ 1.4.8 >= 3.4.2, < 3.5.0 0.67 releases/rn-0.67+taro-3.4.10
1.6.0 ~ 1.6.5 >= 3.5.0, < 3.5.6 0.68 releases/rn-0.68+taro-3.5.5
1.7.0 ~ 1.7.4 >=3.5.6, < 3.6.0 0.69 releases/rn-0.69+taro-3.5.11
1.8.0 ~ >=3.6.0, < 3.7.0 0.70 main

Quick start

install react native library

install peerDependencies of @tarojs/taro-rn @tarojs/components-rn and @tarojs/router-rn, it will also run post-install. please modify and run upgradePeerdeps script when you change taro version.

run this script after the project is initialized.

yarn upgradePeerdeps

pod install

run this script when you add new react native library or update react native library version.

see pod-install for more information.

yarn podInstall

start ios app

yarn ios

start android app

yarn android

start bundler

yarn start

reset cache and start bundler

yarn start --reset-cache

more information

  1. development process of taro react native
  2. github address of the taro project
  3. related articles of taro playground

Release

build ios bundle

yarn build:rn --platform ios

build Android bundle

yarn build:rn --platform android

release ios APP

see publishing-to-app-store for details.

release android apk

see signed-apk-android for details.

Github workflows

use github actions to build your apps. this template include basic github action config.

see .github/workflows for details.

events

we assemble debug and release product for both android and ios when you push or pull request on master branch by default. design your own pipeline by modify .github/workflows files.

see events-that-trigger-workflows

ios

configuration

Modify the following configuration items for package and publish your app.

.github/workflows/assemble_ios_debug.yml .github/workflows/assemble_ios_release.yml

env:
  APP_ID: com.taro.demo # Application Product Bundle Identifier
  APP_NAME: Taro Demo # The Display Name of your app
  VERSION_NUMBER: 1.0.0 # Application version number
  BUILD_NUMBER: 1.0.0.0 # Application build number, used by release only.
  TEAM_ID: XXXXXXXXXX # Team ID, is used when upgrading project
  PROVISIONING_PROFILE_SPECIFIER: Product_profile # Provisioning profile name to use for code signing
  CODE_SIGN_IDENTITY: iPhone Distribution # Code signing identity type (iPhone Developer, iPhone Distribution)
  SIGNING_CERTIFICATE_P12_DATA: ${{secrets.RELEASE_SIGNING_CERTIFICATE_P12_DATA}}
  SIGNING_CERTIFICATE_PASSWORD: ${{secrets.RELEASE_SIGNING_CERTIFICATE_PASSWORD}}
  PROVISIONING_PROFILE_DATA: ${{secrets.RELEASE_PROVISIONING_PROFILE_DATA}}
  APP_STORE_CONNECT_USERNAME: ${{secrets.APP_STORE_CONNECT_USERNAME}} # This secret should be set to the Apple ID of your developer account, used by release only.
  APP_STORE_CONNECT_PASSWORD: ${{secrets.APP_STORE_CONNECT_PASSWORD}} # used by release only.

values like ${{secrets.xxxxx}} are manually generated and store in your github encrypted secrets.

SIGNING_CERTIFICATE_P12_DATA
cat Certificates.p12 | base64 | pbcopy
SIGNING_CERTIFICATE_PASSWORD

encryption password of your Personal Information Exchange (.p12)

PROVISIONING_PROFILE_DATA
cat profile.mobileprovision | base64 | pbcopy
APP_STORE_CONNECT_PASSWORD

This secret should be set to an application-specific password for your Apple ID account. Follow these instructions to create an application-specific password.

read more

  1. deploy an ios app to testflight or the app store using github actions
  2. encrypted-secrets
  3. fastlane

android

configuration

Modify the following configuration items for package and publish your app.

.github/workflows/assemble_android_debug.yml .github/workflows/assemble_android_release.yml

env:
  APP_ID: com.taro.demo  # Application Product Bundle Identifier
  APP_NAME: Taro Demo  # The Display Name of your app
  VERSION_NAME: 1.0.0 # version name
  VERSION_CODE: 10 # version code
  KEYSTORE_FILE: debug.keystore # key store file
  KEYSTORE_PASSWORD: android # key store password
  KEYSTORE_KEY_ALIAS: androiddebugkey # key store key alias
  KEYSTORE_KEY_PASSWORD: android # key store key password

For the security of your app, please regenerate the .keystore file and store the password in your github encrypted secrets.

read more

  1. app signing
  2. encrypted-secrets

Web & Mini Program support

This project supports web and mini program, but it has not been fully tested.

start web server

yarn dev:h5

Github workflows of Web

see peaceiris/actions-gh-pages for more details.

start wechat mini program

yarn dev:weapp

Github workflows of Wechat Mini Program

configuration

We use @tarojs/plugin-mini-ci to deploy mini programs. Modify the following configuration items for package and publish your wechat mini program.

.github/workflows/assemble_weapp_release.yml

env:
  WEAPP_ID: ${{ secrets.WEAPP_ID }} # wechat mini program id
  WEAPP_KEY: ${{ secrets.WEAPP_KEY }} # wechat mini program key

values like ${{secrets.xxxxx}} are manually generated and store in your github encrypted secrets.

WEAPP_KEY
cat private.$WEAPP_ID.key | base64 | pbcopy

Attention

The source code is customized for the Taro playground application and is for reference only. If you want to use it directly, please make the following changes.

  1. Use your own signature file.
  2. Customize your app id, app name, app launcher, etc.
  3. Remove the attention block in ios/Podfile.

For React Native repo debugging

  1. Change appName to taroDemo, which used in AppRegistry.registerComponent(appName, () => App);.
  2. Generate a QR code with content taro://${ip}:${port} or shaking the phone and change bundle Location.

Contributing

We sincerely hope that developers can provide valuable comments and suggestions, and developers can provide feedback on suggestions and problems by submitting PR or Issue.

If you have other questions, you can join the communication group for help.

License

Taro Playground source code is available under the Apache License V2.

Taro and its graphic trademarks are owned by Beijing Jingdong Century Trading Co., Ltd. and licensed to the Taro Playground project.

More Repositories

1

Fair

A Flutter package used to update widget tree dynamically. Fair提供一整套Flutter动态化解决方案
Dart
2,598
star
2

WBBlades

Mach-O based ObjC & Swift useless classes, useless protocols, useless resources detection, packet size analysis, point-to-point crash resolution.基于Mach-O的ObjC & Swift无用类、无用协议、无用资源检测,包大小分析,点对点崩溃解析。
Objective-C
1,530
star
3

Picasso

一款UI自动生成代码插件,提供UI自动生成代码全流程解决方案。
TypeScript
1,126
star
4

react-native-echarts

📈 React Native ECharts Library: An awesome charting library for React Native, built upon Apache ECharts and leveraging react-native-svg and react-native-skia. Offers significantly better performance compared to WebView-based solutions.
TypeScript
729
star
5

Antenna

Antenna是58同城安全团队打造的一款辅助安全从业人员验证网络中多种漏洞是否存在以及可利用性的工具。其基于带外应用安全测试(OAST)通过任务的形式,将不同漏洞场景检测能力通过插件的形式进行集合,通过与目标进行out-bind的数据通信方式进行辅助检测。
JavaScript
719
star
6

Oceanus

58同城数据库中间件
Java
550
star
7

dl_inference

通用深度学习推理工具,可在生产环境中快速上线由TensorFlow、PyTorch、Caffe框架训练出的深度学习模型。
Java
405
star
8

Taro-Mortgage-Calculator

首个 Taro 3 多端统一实例 - 支持 React Native,Weapp,H5。
TypeScript
371
star
9

qa_match

A simple effective ToolKit for short text matching
Python
328
star
10

FairPushy

FairPushy 基于Dart三端一体化动态更新平台,为Flutter Fair设计的动态化框架提供动态分发能力
Dart
268
star
11

metro-code-split

Further split the React Native code based on Metro build to improve performance, providing `Dll` and `Dynamic Imports` features
JavaScript
203
star
12

WPaxos

A production-grade java implementation of paxos consensus algorithm
Java
195
star
13

WLock

A high-reliable, high-throughput distributed lock service based on the consensus algorithm component WPaxos.
Java
184
star
14

magpie

Magpie is a visualized platform which designed to create, develop and compile your standalone flutter module.
Dart
123
star
15

wwto

WWTO,小程序跨端迁移解决方案,低成本将微信小程序转为其他平台(百度、支付宝、头条)小程序。
JavaScript
106
star
16

Zucker

An easier way to automatically calculate the size of AAR in apk based on APP module
Python
88
star
17

LPA-Detector

Optimize and improve the Label propagation algorithm
Java
88
star
18

mp-monitor

mp-monitor脱胎于58内部前端质量监控系统“北斗”。致力于为小程序异常采集和性能统计分析提供采集方案和统一的数据指标,适配多端小程序(微信,头条,支付宝,百度,QQ,360,JD)。 如果开发者想要在自己的项目中快速搭建小程序的异常采集和性能监控数据分析。mp-monitor将能帮助用户快速采集到相关的数据用于分析和监控。
TypeScript
68
star
19

magpie_sdk

A Native-Futter hybrid development solution. Native developers do not need to install FlutterSDK. This Flutter plugin provides general capabilities such as routing management and dynamic protocol registration.
Objective-C
50
star
20

magpie_log

A visualized dynamic programming for log collection based on flutter.
Dart
48
star
21

magpie_fly

Magpie-fly is a component library produced by 58 Group, which encapsulates a variety of common components to meet the needs of developers
Dart
38
star
22

taro-visualization

TypeScript
33
star
23

json-model-validator

A flexible, lightweight JSON Data validator and formatter
TypeScript
30
star
24

wsilk

wsilk是一个辅助开发人员的代码生成框架(wsilk is a framework that assists developers to generate code)
Java
26
star
25

Taro-Code-In-React-Native

Taro React Native 参考样例。支持在 React Native 初始化的项目中引入 Taro 3 代码。
JavaScript
22
star
26

EasyAOP

EasyAOP是基于ASM实现切面通用能力的工具。EasyAOP提供的通用切面能力,可以使用配置文件方式来配置使用。(EasyAOP is a tool based on ASM to realize the general capability of AOP. General faceting capabilities provided by EasyAOP,You can use the yaml file format to configure the use of EasyAOP.)
Kotlin
22
star
27

first-meaning-paint

首次有效绘制表示当前页面最想展示给用户的元素渲染的时间点,即主元素渲染点。
JavaScript
11
star
28

FairTemplate

FairTemplate 是为Fair 开发者设计的常用基础组件库及代码模板,结合Fair 团队自研的IDE 插件,快速地搭建Fair 动态化页面,提升Fair 的开发效率。
Dart
5
star
29

ideaPlugin-MavenManager

Manage dependencies of maven project to resolve jar conflicts
Java
3
star