攜手創作,共同成長!這是我參與「掘金日新計劃 · 8 月更文挑戰」的第4天,點擊查看活動詳情
The birth of this article is very accidental,In the past two days, a little boy asked the eraser an old question,Python 基礎學完了,want to learn one Python Web 框架,是先學習 Django 呢,還是學習 Flask,What is the company using now??
every time this problem occurs,I will pull up a list,This time let's convert it directly into an article.
標題就叫做《2022 年,what you should learn Python Web 框架》
All frameworks covered below,Neither the official website nor any learning materials are provided,作為一個合格的程序員,You have to find these.
Let's learn this,輕便,靈活,定制性強,The point is to get started,and popular,
Eraser knows a lot Python Web The engineer will take this small job to do,==do it fast,來錢也快==.
Logo is a pepper icon,比較火熱~
Python Web big brother in frame,大而全,Comes with a bunch of features,學會了之後,做後台管理系統,安裝之後,Just a few configurations.
有一定的學習門檻,Framework pattern follows MTV 模式,即模型,視圖,模板.
If you are a beginner django,掌握之後,回過頭來看 Flask,==呃,Small projects you will choose without hesitation Flask==.
是 Python Web 框架的同時,It is also an asynchronous network library,使用的是非阻塞 IO,所以處理速度特別快. 性能優秀,Excellent with high concurrency,But because it involves asynchrony IP 相關知識,So for beginners don't friendly,That is to say, the difficulty of learning is so high.
如果你 Python 基礎還不錯,那 tornado Also a lightweight for you Web 框架,and supports asynchronous programming and Web Socket,must learn this.
一個遵循 WSGI 的微型 Web 框架,The whole shelf is a dozen K 的文件,contains routing,模板,simple data access,6 的飛起.
But it is also because of it“太簡陋"了,learn it,So people always ignore it.
不新不舊,A lukewarm frame,基於 Python3.6+實現,支持 async/await 語法,So it is also an efficient framework.
The current problem is the lack of data,The ecology is not so good(Sanic Plugin documentation is almost non-existent),But the learning stage is definitely enough,語法非常類似 Flask,So I choose both Flask.
但是注意一點 Sanic 是異步框架,性能優於 Flask.
沒錯,The hottest fried”現代“ Python Web 框架,Known as the first performance,Encoding speed first,Documentation is easiest,It can also help programmers reduce errors.
one more thing new,2019 年的框架,It's so hot now,So you have to learn.
In addition to the framework mentioned above,There are also some minorities,or a wheel frame for special scenes.
如果你學有余力,can do some research.
A high-performance tool for building large-scale applications and microservices Python Web 框架.
Known for efficient and fast-paced development Python Web 框架.
支持異步的 Web 框架.
The promotion is more focused on the product,簡化開發過程,A framework to simplify grammar.
Guess the name,It is a focus on Python Api 的框架.
hug 的定義是一個 RESTFUL API 的框架,Framework for interface platform
BlackSheep 是一個異步 Web 框架,語法與 Flask 類似.
Focused on optimizing the route lookup function,Because of the claims to be the fastest Python Web 框架之一,But colleagues call themselves that. But its name is really unflattering,After all the eraser always creates a file called index.py
的文件.
一個輕量級的 ASGI 框架,In the back, the eraser will add an introduction to everyone ASGI 知識點的文章.
底層是 starlette
,是 kennethreitz
寫的,Quality is guaranteed,who is this big guy?requests
模塊的作者.
自己搜搜吧,這個不太了解,資料也不多.
Is also a small mini development API 的框架
Write the crawler commonly used,基於 asyncio 和 異步 Web 框架.
與其它框架不同,cherrypy 有自己的想法,It expects developers to develop in accordance with object-oriented ideas Web 系統,So you can focus on this framework.
以 Django A framework for competitors,You should know what it is by now.
Cyclone 將 Tornado API 實現為 Twisted 協議.
好家伙,這個是 Django 和 FastApi 的結合體,官方說的是 Fast Django REST Framework,And the slogan is:fast to learn,fast to code,fast to run,厲害,厲害.
Guido van Rossum 認為這是最好的 Python Web 框架,Too bad the author is no longer there.
Python Web 框架非常多,many did not appear above,一個 Python Web Engineers only need to learn before 6 款即可,The rest of the study can work. In this article, you can collect,Then one thousand which day to~