jedcunningham commented on code in PR #28537:
URL: https://github.com/apache/airflow/pull/28537#discussion_r1055827387


##########
docs/apache-airflow/howto/custom-view-plugin.rst:
##########
@@ -48,73 +43,32 @@ Custom view Registration
 ------------------------
 
 A custom view with object reference to flask_appbuilder and Blueprint from 
flask
-and be registered as a part of a :doc:`plugin 
</authoring-and-scheduling/plugins>`. The following is a
-skeleton for us to implement a new custom view:
+and be registered as a part of a :doc:`plugin 
</authoring-and-scheduling/plugins>`.
 
-.. code-block:: python
-
-    from airflow.plugins_manager import AirflowPlugin
-    from flask import Blueprint
-    from flask_appbuilder import BaseView
-
-
-    class MetastoreBrowserView(BaseView):
-        pass
-
-
-    # Creating a flask blueprint to integrate the templates and static folder
-    bp = Blueprint(
-        "metastore_browser",
-        __name__,
-        template_folder="templates",
-        static_folder="static",
-        static_url_path="/static/metastore_browser",
-    )
+The following is a skeleton for us to implement a new custom view:
 
+.. exampleinclude:: ../../../empty_plugin/empty_plugin.py

Review Comment:
   Can we put this in docs/apache-airflow (or somewhere) instead of the repo 
root? We have enough top level items, this seems like an easy one to remove.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@airflow.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to