We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a77b7ca commit 36cf175Copy full SHA for 36cf175
1 file changed
learnpython/app.py
@@ -8,14 +8,17 @@
8
from learnpython import settings
9
10
11
+# Initialize Flask application
12
app = Flask('learnpython')
13
app.config.from_object(settings)
14
15
+# Configure all necessary plugins
16
babel = Babel(app)
17
mail = Mail(app)
18
manager = Manager(app)
19
pages = FlatPages(app)
20
21
+# Register all possible urls
22
views = LazyViews(app, '.views')
23
views.add('/', redirect, defaults={'code': 301, 'location': '/index'})
24
views.add('/<any(about, index):name>', 'page')
@@ -27,3 +30,4 @@
27
30
defaults={'name': 'subscribe'},
28
31
endpoint='subscribe',
29
32
methods=('GET', 'POST'))
33
+views.add_static('/favicon.ico', defaults={'filename': 'img/favicon.ico'})
0 commit comments