https://github.com/stevej2608/reactpy-github-buttons
ReactPy wrapper for github-buttons
https://github.com/stevej2608/reactpy-github-buttons
github-buttons python reactpy
Last synced: 2 days ago
JSON representation
ReactPy wrapper for github-buttons
- Host: GitHub
- URL: https://github.com/stevej2608/reactpy-github-buttons
- Owner: stevej2608
- License: mit
- Created: 2023-12-18T11:38:46.000Z (about 2 years ago)
- Default Branch: master
- Last Pushed: 2025-12-22T11:50:27.000Z (about 1 month ago)
- Last Synced: 2025-12-22T16:58:45.500Z (about 1 month ago)
- Topics: github-buttons, python, reactpy
- Language: JavaScript
- Homepage:
- Size: 13.7 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
## reactpy-github-buttons

Minimal [ReactPy] wrapper for [github-buttons].
## Usage
pip install reactpy-github-buttons
## Examples
Several examples of usage are in the *./examples* folder.
### Minimal
*./examples/single.py*
```
from reactpy import component, html, run
from reactpy_github_buttons import StarButton
@component
def AppMain():
return StarButton(user='reactive-python', repo='reactpy')
if __name__ == "__main__":
run(AppMain)
```
### With Color Scheme
*./examples/color_scheme.py*
```
from reactpy import component, html, run
from reactpy_github_buttons import StarButton, make_color_scheme, ColorScheme
@component
def AppMain():
return StarButton(user='reactive-python', repo='reactpy',
show_count=True,
color_scheme=make_color_scheme(
no_preference=ColorScheme.LIGHT_HIGH_CONTRAST,
light=ColorScheme.LIGHT,
dark=ColorScheme.DARK_HIGH_CONTRAST,
)
)
if __name__ == "__main__":
run(AppMain)
```
### Buttons Playground
The [Buttons Playground](https://buttons.github.io/) application has been implemented
as a RectPy demonstrator.
python -m examples.button_playground

[github-buttons]: https://github.com/buttons/github-buttons
[ReactPy]: https://github.com/reactive-python/reactpy