From 01dc1709c427718d5f46b75fff3c701a4cabe14d Mon Sep 17 00:00:00 2001 From: "55448286+taizan-hokuto@users.noreply.github.com" Date: Sun, 3 Nov 2019 09:39:58 +0900 Subject: [PATCH] Update README --- README.md | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index eebcc8a..d2190c0 100644 --- a/README.md +++ b/README.md @@ -15,12 +15,12 @@ Other features: instead of web scraping. ## Install -``` +```python pip install pytchat ``` ## Examples -``` +```python from pytchat import LiveChat chat = LiveChat("G1w62uEMZ74") @@ -31,12 +31,13 @@ while chat.is_alive(): data.tick() ``` -callback mode -``` +###callback mode +```python from pytchat import LiveChat chat = LiveChat("G1w62uEMZ74", callback = func) while chat.is_alive(): + #other background operation here. time.sleep(3) def func(chatdata): @@ -45,8 +46,8 @@ def func(chatdata): chat.tick() ``` -asyncio context: -``` +###asyncio context: +```python from pytchat import LiveChatAsync import asyncio @@ -66,8 +67,8 @@ loop.run_until_complete(main()) ``` -yt api compatible processor: -``` +###yt api compatible processor: +```python from pytchat import LiveChat, CompatibleProcessor chat = LiveChat("G1w62uEMZ74", @@ -194,4 +195,6 @@ Structure of author object. ## Author -[taizan-hokuto](https://github.com/taizan-hokuto) \ No newline at end of file +[taizan-hokuto](https://github.com/taizan-hokuto) + +[twitter:@taizan205](https://twitter.com/taizan205) \ No newline at end of file