Skip to content

Commit a0458ef

Browse files
authored
refactor or remove old docs (pallets#4748)
1 parent 45b2c99 commit a0458ef

10 files changed

+43
-681
lines changed

docs/advanced_foreword.rst

-46
This file was deleted.

docs/config.rst

+6-10
Original file line numberDiff line numberDiff line change
@@ -394,13 +394,11 @@ The following configuration values are used internally by Flask:
394394
Configuring from Python Files
395395
-----------------------------
396396

397-
Configuration becomes more useful if you can store it in a separate file,
398-
ideally located outside the actual application package. This makes
399-
packaging and distributing your application possible via various package
400-
handling tools (:doc:`/patterns/distribute`) and finally modifying the
401-
configuration file afterwards.
397+
Configuration becomes more useful if you can store it in a separate file, ideally
398+
located outside the actual application package. You can deploy your application, then
399+
separately configure it for the specific deployment.
402400

403-
So a common pattern is this::
401+
A common pattern is this::
404402

405403
app = Flask(__name__)
406404
app.config.from_object('yourapplication.default_settings')
@@ -692,10 +690,8 @@ your configuration files. However here a list of good recommendations:
692690
code at all. If you are working often on different projects you can
693691
even create your own script for sourcing that activates a virtualenv
694692
and exports the development configuration for you.
695-
- Use a tool like `fabric`_ in production to push code and
696-
configurations separately to the production server(s). For some
697-
details about how to do that, head over to the
698-
:doc:`/patterns/fabric` pattern.
693+
- Use a tool like `fabric`_ to push code and configuration separately
694+
to the production server(s).
699695

700696
.. _fabric: https://www.fabfile.org/
701697

docs/design.rst

+24-1
Original file line numberDiff line numberDiff line change
@@ -130,9 +130,25 @@ being present. You can easily use your own templating language, but an
130130
extension could still depend on Jinja itself.
131131

132132

133-
Micro with Dependencies
133+
What does "micro" mean?
134134
-----------------------
135135

136+
“Micro” does not mean that your whole web application has to fit into a single
137+
Python file (although it certainly can), nor does it mean that Flask is lacking
138+
in functionality. The "micro" in microframework means Flask aims to keep the
139+
core simple but extensible. Flask won't make many decisions for you, such as
140+
what database to use. Those decisions that it does make, such as what
141+
templating engine to use, are easy to change. Everything else is up to you, so
142+
that Flask can be everything you need and nothing you don't.
143+
144+
By default, Flask does not include a database abstraction layer, form
145+
validation or anything else where different libraries already exist that can
146+
handle that. Instead, Flask supports extensions to add such functionality to
147+
your application as if it was implemented in Flask itself. Numerous extensions
148+
provide database integration, form validation, upload handling, various open
149+
authentication technologies, and more. Flask may be "micro", but it's ready for
150+
production use on a variety of needs.
151+
136152
Why does Flask call itself a microframework and yet it depends on two
137153
libraries (namely Werkzeug and Jinja2). Why shouldn't it? If we look
138154
over to the Ruby side of web development there we have a protocol very
@@ -201,5 +217,12 @@ requirements and Flask could not meet those if it would force any of this
201217
into the core. The majority of web applications will need a template
202218
engine in some sort. However not every application needs a SQL database.
203219

220+
As your codebase grows, you are free to make the design decisions appropriate
221+
for your project. Flask will continue to provide a very simple glue layer to
222+
the best that Python has to offer. You can implement advanced patterns in
223+
SQLAlchemy or another database tool, introduce non-relational data persistence
224+
as appropriate, and take advantage of framework-agnostic tools built for WSGI,
225+
the Python web interface.
226+
204227
The idea of Flask is to build a good foundation for all applications.
205228
Everything else is up to you or extensions.

docs/foreword.rst

-53
This file was deleted.

docs/htmlfaq.rst

-206
This file was deleted.

0 commit comments

Comments
 (0)