Permalink
Browse files

Move docs explaining instantiating Flask

  • Loading branch information...
Alex Couper
Alex Couper committed Feb 22, 2013
1 parent a92588f commit cc8a85d7539bf7f1a6a0affd55f338e46af0d1c1
Showing with 8 additions and 9 deletions.
  1. +8 −9 docs/quickstart.rst
View
@@ -38,15 +38,14 @@ should see your hello world greeting.
So what did that code do?
1. First we imported the :class:`~flask.Flask` class. An instance of this
- class will be our WSGI application. The first argument is the name of
- the application's module. If you are using a single module (as in this
- example), you should use `__name__` because depending on if it's started as
- application or imported as module the name will be different (``'__main__'``
- versus the actual import name). For more information, have a look at the
- :class:`~flask.Flask` documentation.
-2. Next we create an instance of this class. We pass it the name of the module
- or package. This is needed so that Flask knows where to look for templates,
- static files, and so on.
+ class will be our WSGI application.
+2. Next we create an instance of this class. The first argument is the name of
+ the application's module or package. If you are using a single module (as
+ in this example), you should use `__name__` because depending on if it's
+ started as application or imported as module the name will be different
+ (``'__main__'`` versus the actual import name). For more information, have
+ a look at the :class:`~flask.Flask` documentation. This is needed so that
+ Flask knows where to look for templates, static files, and so on.
3. We then use the :meth:`~flask.Flask.route` decorator to tell Flask what URL
should trigger our function.
4. The function is given a name which is also used to generate URLs for that

0 comments on commit cc8a85d

Please sign in to comment.