Skip to main content

amis-python

license python version

基于 百度amis 前端框架的python pydantic模型封装。

由于原版本缺少大量amis新版本的组件或配置,因此本项目在其版本的基础上进行了扩充。

相比fastapi-amis-admin的版本:

  • 涵盖amis截至3.1.0版本的所有组件
  • 使用jinja2模板
  • 支持修改主题

安装

pip install amis-python

简单使用

from amis.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 amis-python 1.0.8.post2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for amis-python 1.0.8.post2
File Size Uploaded Provenance Actions
amis_python-1.0.8.post2.tar.gz 56.5 kB Without provenance Details for amis_python-1.0.8.post2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for amis-python 1.0.8.post2
File Interpreter ABI Platform Actions
amis_python-1.0.8.post2-py3-none-any.whl Python 3 none any Details for amis_python-1.0.8.post2-py3-none-any.whl

Total release size: 115.0 kB

Release files / amis_python-1.0.8.post2.tar.gz

Download URL amis_python-1.0.8.post2.tar.gz
Size 56.5 kB
Tags Source
SHA-256 checksum
How to use checksums
83c62fd68f7ac778d41b4b9312e0bc1d1f8418f8a6c1a993d23c0e74ba1af5fb
BLAKE2b-256 checksum
How to use checksums
2e04282fd64df0b50c93e58b41af67c195c64a2d9b72848dd3951ce3b9baca6d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.17

Release files / amis_python-1.0.8.post2-py3-none-any.whl

Download URL amis_python-1.0.8.post2-py3-none-any.whl
Size 58.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
92a9b5515ae901f57bb90281224663987b96bb16a81e56ce26fb390bb3bd550a
BLAKE2b-256 checksum
How to use checksums
86b82e80da5abf70fd80278621a0fc8a40e2b177767417caa9ecff05464b2a42
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.17

Security for amis-python 1.0.8.post2

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page