amis-python
基于 百度amis 前端框架的python pydantic模型封装。
由于原版本缺少大量amis新版本的组件或配置,因此本项目在其版本的基础上进行了扩充。
相比fastapi-amis-admin的版本:
- 涵盖amis截至3.1.0版本的所有组件
- 使用jinja2模板
- 支持修改主题
安装
pip install amisui
简单使用
from amisui.components import Page
page = Page(title='新页面', body='Hello World')
# 输出为python字典
print(page.to_dict())
# 输出为json
print(page.to_json())
# 输出为str
print(page.render())
# 保存为html文件
with open('HelloWorld.html', 'w', encoding='utf-8') as f:
f.write(page.render())
详细使用
详见amis官方文档
感谢
Metadata
Release files for amisui 0.1.6
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| amisui-0.1.6.tar.gz | 56.5 kB | Without provenance | Details for amisui-0.1.6.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| amisui-0.1.6-py3-none-any.whl | Python 3 | none | any | Details for amisui-0.1.6-py3-none-any.whl |
Total release size: 115.0 kB
Release files / amisui-0.1.6.tar.gz
| Download URL | amisui-0.1.6.tar.gz |
|---|---|
| Size | 56.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b130f0375934c52376ee187682fd41a1e8445dceeacebbfac720b66f43a80208
|
|
BLAKE2b-256 checksum How to use checksums |
b237a7a8288d3d01da5adecfd8ea72a0907b9b68a7d5062b69e12a9b1e048489
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
pdm/2.15.4 CPython/3.10.12 Linux/6.5.0-1021-azure
|
Release files / amisui-0.1.6-py3-none-any.whl
| Download URL | amisui-0.1.6-py3-none-any.whl |
|---|---|
| Size | 58.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0c23afd13c501764e85cadb31f692c681b12886931cee8b996293fd3de0397bf
|
|
BLAKE2b-256 checksum How to use checksums |
29bf7fd3bce17e0b118ffbe2227a59d72ad8a25038c3f46e8fea47cc3b7ba54b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
pdm/2.15.4 CPython/3.10.12 Linux/6.5.0-1021-azure
|
Security for amisui 0.1.6
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.