Browse Source

Update 'README.md'

天问 1 year ago
parent
commit
79ff5fc814
1 changed files with 4 additions and 1 deletions
  1. 4 1
      README.md

+ 4 - 1
README.md

@@ -1,7 +1,7 @@
 # flask_restful
 为 Flask 框架提供支持的 RESTful API 扩展
 
-继承 Resource 类,并覆盖其中的方法来处理不同的 HTTP 请求
+
 
 ## Usage
 
@@ -12,7 +12,10 @@ from flask_restful import Resource, Api
 app = Flask(__name__)
 api = Api(app)
 
+# 接口需要继承 Resource 类
 class HelloWorld(Resource):
+    
+    # 覆写get,post等方法处理 HTTP 请求
     def get(self):
         return {'hello': 'world'}