Skip to main content
Version: 3.x

CONTRIBUTING

We are happy to welcome developers from the community to contribute to Taro 《Taro invites you to join in community building》

  • Submit an RFC or view the relevant RFC, you can view taro-rfcs repository
  • Share your case, just submit the mini program QR code, you can submit to taro-user-cases
  • Share your SDK, components , UI libary, project, you can submit to Examples
  • Share your experience (open source projects, tutorials, articles) you can submit to awesome-taro Or contribute to the 「Taro Community」Official Accounts

Before submitting your code for contribution, you need to spend some time reading the following to ensure that the contribution is in compliance with the specification and will help the community.

Taro Composition

NPM PackageDescription
babel-preset-taroThe babel preset for Taro projects
@tarojs/taroTaro's core API for application developers
@tarojs/sharedThe utils used internally by Taro
@tarojs/apiPublic API for all platform of @tarojs/taro
@tarojs/taro-h5H5 API for @tarojs/taro
@tarojs/routerTaro H5 Router
@tarojs/reactReact renderer for mini program based on react-reconciler
@tarojs/cliTaro Development Tools
@tarojs/extendTaro extensions, including jQuery API, etc.
@tarojs/helperInternal use of auxiliary method sets for CLI and runner
@tarojs/serviceTaro Plugin Kernel
@tarojs/taro-loaderWebpack loader exposed for use by @tarojs/mini-runner and @tarojs/webpack-runner
@tarojs/runner-utilsCommon tool functions exposed to @tarojs/mini-runner and @tarojs/webpack-runner
@tarojs/webpack-runnerTaro H5 Webpack package builder
@tarojs/mini-runnerTaro mini program Webpack package tools
@tarojs/componentsTaro H5 Standard component library
@tarojs/taroizeTaro Mini Program Reverse compiler
@tarojs/with-weappRuntime adapter for reverse conversion
eslint-config-taroTaro ESLint Rules
eslint-plugin-taroTaro ESLint Plugin

Issue Guides

If you are submitting a bug report, please click New issue

If you want to implement an important feature for Taro, you need to write an RFC document first, following Taro's RFC System,The code can be submitted only after it has been discussed and refined by the community.

Develop Configuration

You need to make sure your Node.js version is greater than 8 to clone the repository locally. Run the following command.

$ npm install # or yarn
$ npm run bootstrap
$ npm run build

Submit Code

Taro repository adheres to the Angular Style Commit Message Conventions,So be sure to follow this when entering your commit message, please make sure to follow this convention when publish.

Code Style

  • JavaScript:JavaScript style Follow JavaScript Standard Style
  • TypeScript:TypeScript style Follow [JavaScript Standard Style](https://github.com/standard/See tslint.json and tsconfig.json in the relevant package directory for details.
  • Styles:follow the .stylelintrc style in the relevant package directory.

Pull Request Guides

  1. Make sure that npm run build compiles successfully;
  2. Be sure to submit code that follows the specifications specified in .eslintrc, .tslintrc, .stylelintrc in the relevant package;
  3. When the package.json of the package in question contains the npm test command, it must be ensured that all test cases are required to pass;
  4. When a test case is available for the package in question, add the corresponding test case to your submitted code as well;
  5. When contribute Code, the commit message needs to follow Angular Style Commit Message Conventions
  6. If the contribute code is very complex, you can split the PR into several commits. We will squash when merging.

Credits

Thanks to all the developers who have contributed code to Taro: