We'd love to accept your patches and contributions to this project.
Contributions to this project must be accompanied by a Contributor License Agreement (CLA). You (or your employer) retain the copyright to your contribution; this simply gives us permission to use and redistribute your contributions as part of the project.
If you or your current employer have already signed the Google CLA (even if it was for a different project), you probably don't need to do it again.
Visit https://cla.developers.google.com/ to see your current agreements or to sign a new one.
This project follows Google's Open Source Community Guidelines.
All submissions, including submissions by project members, require review. We use GitHub pull requests for this purpose. Consult GitHub Help for more information on using pull requests.
You may follow these steps to contribute:
- Fork the official repository. This will create a copy of the official repository in your own account.
- Sync the branches. This will ensure that your copy of the repository is up-to-date with the latest changes from the official repository.
- Work on your forked repository's feature branch. This is where you will make your changes to the code.
- Commit your updates on your forked repository's feature branch. This will save your changes to your copy of the repository.
- Submit a pull request to the official repository's main branch. This will request that your changes be merged into the official repository.
- Resolve any linting and formatting errors. Run
./scripts/fix_format.shto fix formatting issues.
Here are some additional things to keep in mind during the process:
- Test your changes. Before you submit a pull request, make sure that your changes work as expected.
- Be patient. It may take some time for your pull request to be reviewed and merged.
To keep our codebase consistent and maintainable, we follow specific coding standards and use automated formatters.
- JavaScript / TypeScript / JSON / Markdown / CSS: Prettier
- Python: Pyink (Google style Black)
- Dart:
dart format
You can use the provided script to format the entire repo or check formatting:
./scripts/fix_format.sh
./scripts/fix_format.sh --checkWe recommend using VS Code for development. To help enforce formatting, please install the following extensions:
- Prettier - Code formatter (
esbenp.prettier-vscode) - Black Formatter (
ms-python.black-formatter) - configured to usepyinkin workspace settings. - Dart (
Dart-Code.dart-code)
Workspace settings are provided in .vscode/settings.json to use these formatters by default on save.
Please refer to the following guidelines for detailed information on styles:
- Python: Google Python Style Guide.
- TypeScript: Google TypeScript Style Guide.
- License Headers: required copyright notices.
We expect all contributors to adhere to these styles.
For Google-internal information see go/a2ui-internal.