index.rst
This file
Path
docs/tutorial/index.rst
66 lines · 2.0 KiB
Last changed by
Merge pull request #2676 from davidism/tutorialDavid Lordbefore adoptionc3e2ff2
History of this fileTake it
The walk stopped after 200 commits: lines older than 6a8c8c3 point at it.
set example app names directlyDavid Lordbefore adoption6a8c8c3
lines 1–5why, one step back1.. _tutorial:23Tutorial4========5Merge pull request #2676 from davidism/tutorialDavid Lordbefore adoptionc3e2ff2
lines 6–8why, one step back6.. toctree::7 :caption: Contents:8 :maxdepth: 1set example app names directlyDavid Lordbefore adoption6a8c8c3
line 9why, one step back9Merge pull request #2676 from davidism/tutorialDavid Lordbefore adoptionc3e2ff2
lines 10–20why, one step back10 layout11 factory12 database13 views14 templates15 static16 blog17 install18 tests19 deploy20 nextset example app names directlyDavid Lordbefore adoption6a8c8c3
line 21why, one step back21Merge pull request #2676 from davidism/tutorialDavid Lordbefore adoptionc3e2ff2
lines 22–25why, one step back22This tutorial will walk you through creating a basic blog application23called Flaskr. Users will be able to register, log in, create posts,24and edit or delete their own posts. You will be able to package and25install the application on other computers.set example app names directlyDavid Lordbefore adoption6a8c8c3
line 26why, one step back26Merge pull request #2676 from davidism/tutorialDavid Lordbefore adoptionc3e2ff2
lines 27–30why, one step back27.. image:: flaskr_index.png28 :align: center29 :class: screenshot30 :alt: screenshot of index pageset example app names directlyDavid Lordbefore adoption6a8c8c3
line 31why, one step back31Merge pull request #2676 from davidism/tutorialDavid Lordbefore adoptionc3e2ff2
lines 32–33why, one step back32It's assumed that you're already familiar with Python. The `official33tutorial`_ in the Python docs is a great way to learn or review first.set example app names directlyDavid Lordbefore adoption6a8c8c3
line 34why, one step back34Merge pull request #2676 from davidism/tutorialDavid Lordbefore adoptionc3e2ff2
line 35why, one step back35.. _official tutorial: https://docs.python.org/3/tutorial/set example app names directlyDavid Lordbefore adoption6a8c8c3
line 36why, one step back36Merge pull request #2676 from davidism/tutorialDavid Lordbefore adoptionc3e2ff2
lines 37–66why, one step back37While it's designed to give a good starting point, the tutorial doesn't38cover all of Flask's features. Check out the :ref:`quickstart` for an39overview of what Flask can do, then dive into the docs to find out more.40The tutorial only uses what's provided by Flask and Python. In another41project, you might decide to use :ref:`extensions` or other libraries to42make some tasks simpler.4344.. image:: flaskr_login.png45 :align: center46 :class: screenshot47 :alt: screenshot of login page4849Flask is flexible. It doesn't require you to use any particular project50or code layout. However, when first starting, it's helpful to use a more51structured approach. This means that the tutorial will require a bit of52boilerplate up front, but it's done to avoid many common pitfalls that53new developers encounter, and it creates a project that's easy to expand54on. Once you become more comfortable with Flask, you can step out of55this structure and take full advantage of Flask's flexibility.5657.. image:: flaskr_edit.png58 :align: center59 :class: screenshot60 :alt: screenshot of login page6162:gh:`The tutorial project is available as an example in the Flask63repository <examples/tutorial>`, if you want to compare your project64with the final product as you follow the tutorial.6566Continue to :doc:`layout`.