1 Star 0 Fork 261

cloudsky / zvt

forked from foolcage / zvt 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
code_of_conduct.md 623 Bytes
一键复制 编辑 原始数据 按行查看 历史

1. 命名

  • snake_case适用于

    • variable(变量)
    • package(包)
    • module(模块)
    • function(函数)
    • method(方法)
  • CamelCase适用于

    • class(类)

2. 对外接口

各module对外暴露的接口应显式声明于__all__,例子:

contract模块以此结尾:

__all__ = ['IntervalLevel', 'Mixin', 'NormalMixin', 'EntityMixin', 'NormalEntityMixin', 'zvt_context']

3. 引入接口

不要使用 from zvt.module import *,你要什么就import什么,不要污染。

4. 没了

No api is the best api.

Code as comment.

Python
1
https://gitee.com/lilogo/zvt.git
git@gitee.com:lilogo/zvt.git
lilogo
zvt
zvt
master

搜索帮助