Describe the bug
Currently, we have a lot of examples of different use cases in sanic. However, it's missing from the Documentation.
Code snippet
NA
Expected behavior
It will be good if we can have a reference to each of the example code with some brief description in the Documentation section so that everything can be found under a common roof.
Environment (please complete the following information):
NA
Additional context
NA
Examples and a "tutorial" was something I have been wanting to add to a beefed up home page and documentation. After this next release I am hoping we can get a few people working together to make a big push on this effort. Care to help?
@ahopkins Yes. I'm always game for documentation. I also noticed that some of the APIs are missing documentation that needs to be included.
@ahopkins I added a few items under the checkbox to track the things that need to go into Documentation update. Please feel free to update it as applicable.
Will do. @sjsadowski... want to add this to the project board?
@ahopkins @harshanarayana I've been thinking about building out examples but I'd like a little clarity.
Would it be better to showcase connecting to a low-level db using an async driver, or would it be better to incorporate a few examples that users would likely be using - like asyncpg?
@LBWright it's better to keep the examples as exhaustive as possible. Both items you mentioned has its own advantage but caters to two different level of audiences. So, why limit when we add examples? We add both and let the end user decide which one they want to use.
Sounds good! I just wanted to make sure I had permission to start libraries into my examples.
@LBWright we sure need any kind of example possible, from the simplest "hello world" to advanced asyncio hacks and integrations. If you look at what has been asked in the issues so far, gitter and in the community forums, you would be surprised on the variety of topics :wink:
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. If this is incorrect, please respond with an update. Thank you for your contributions.
Looking at the recent posts in community forum, I found some examples with different use cases, and I think it would be nice to have in Documentation:
CelerySome more examples with ORM:
The first feeling I get of that list of things that none of them are strongly related to Sanic and will definitely be better documented elsewhere.
One thing that bothered me when coming to Sanic is the mention of deployment with daphne, uvicorn and hypercorn but no tips on which to use, or if this even has any benefits over the built-in server.
The new sanic-guide repo (that houses the Sanic frontpage) has a section for this. Over the next few months, I hope to fill that out.