quokka-plugins

973

扩展

Quokka 尝试使用类似Django-ish的方法去实现quokka-modules,你能通过以下方式去开发modules:

quokka/modules

└── posts
├── admin.py – defines the admin pages
├── commands.py – create management commands here
├── __init__.py – define module and routes
├── models.py – define the Mongo Documents models
├── populate.py – optional example fixtures
├── tasks.py – Tasks is for celery tasks
├── template_filters.py – Jinja filters
├── templates
│      └── posts
│      ├── detail.html
│      └── list.html
└── static
└── views.py – module views

重要:通过阅读开发模块的文档,你能了解到更多内容。模块取名时应该遵照文档规范,避免名称冲突。

安装模块

安装模块不需要改变现有代码或者配置文件。
仅仅将其放入quokka/modules目录下,然后重启服务即可。
Quokka admin也提供了一个web接口让admin用户可以安装、启用、停用模块。

原文:https://github.com/quokkaproject/quokka/wiki/plugins

留下一个答复

Please enter your comment!
Please enter your name here