Python fork and translation of Ink for building terminal UIs
Project description
pyinkcli
A Python fork and translation project of Ink for building terminal UIs with a React-like component model.
pyinkcli is a Python implementation inspired by and translated from Ink. This repository is a fork, not the official Node.js package, and the API is adapted for Python where needed.
Install
pip install pyinkcli
Quick Start
from pyinkcli import Box, Text, render
def Counter():
return Box(
Text("Hello from pyinkcli", color="green", bold=True),
flexDirection="column",
alignItems="center",
)
app = render(Counter)
app.wait_until_exit()
What This Repo Is
- A Python fork of Ink focused on translating the terminal UI model into Python
- A repo that keeps the upstream JS implementation nearby for parity work and audits
- A place for Python-native examples and tests under
examples/andtests/
Examples
examples/alternate-screen/examples/chat/examples/counter/examples/terminal-resize/examples/use-focus/examples/use-input/
License
MIT. The repository includes the upstream Ink license text in LICENSE.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pyinkcli-0.1.2.tar.gz.
File metadata
- Download URL: pyinkcli-0.1.2.tar.gz
- Upload date:
- Size: 68.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2034f509580333baf16ee549b8e3f6af758b23b6b49e42522b852d8d1c4e1fd6
|
|
| MD5 |
9f5b54c821b31fd0d1f7c8e8068792e1
|
|
| BLAKE2b-256 |
6a59ac11a4e14b4f520af68578b7b85bad287337ae397dfe294b28c9111ac863
|
File details
Details for the file pyinkcli-0.1.2-py3-none-any.whl.
File metadata
- Download URL: pyinkcli-0.1.2-py3-none-any.whl
- Upload date:
- Size: 105.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e588be86f8f7f68ba7e68387a1502ea12ed8d839ee81a7450cc4ea12717408b2
|
|
| MD5 |
341e15083fd7f055714e22ff0214dccc
|
|
| BLAKE2b-256 |
6bfe2f716ad3044c1eb5fd290773cf90e5a69559c3c5a4c41d6cee26c13a3b6a
|