📝 update adapter connection guide

This commit is contained in:
yanyongyu
2020-12-02 15:14:24 +08:00
parent 0d5930fc3a
commit 064ed81758
3 changed files with 29 additions and 1 deletions

View File

@ -16,8 +16,11 @@ nb create
```python{3,4,7}
import nonebot
from nonebot.adapters.cqhttp import Bot as CQHTTPBot
nonebot.init()
driver = nonebot.get_driver()
driver.register_adapter("cqhttp", CQHTTPBot)
nonebot.load_builtin_plugins()
if __name__ == "__main__":