typos
parent
0fd1547e67
commit
82ecef8433
1 changed files with 4 additions and 4 deletions
|
|
@ -36,7 +36,7 @@ Ok, so from now, we should have all the libs ready. Here the folder structures:
|
|||
app.db
|
||||
app/__init__.py
|
||||
app/constants.py
|
||||
app/static
|
||||
app/static/
|
||||
|
||||
For every module (or sub app... ) well have this file structure (here for the users module)
|
||||
|
||||
|
|
@ -54,13 +54,13 @@ for every module that need templating (jinja) we store those in the templates fo
|
|||
app/templates/users/register.html
|
||||
...
|
||||
|
||||
for the static file, flask will automagically serve static files from this static folder. If you want to use another folder... you can read about that here: http://flask.pocoo.org/docs/api/#application-object
|
||||
for the static file you should serve them with a dedicated http server, but being in at a dev stage, we'll let flask serve them. Flask will automagically serve static files from this static folder. If you want to use another folder... you can read about that here: http://flask.pocoo.org/docs/api/#application-object
|
||||
|
||||
app/static/js/main.js
|
||||
app/static/css/reset.css
|
||||
app/static/img/header.png
|
||||
|
||||
We'll create 4 modules, a user module (manage user's registration, login, password lost, profile edit and maybe Third party Login/Registration) an emails sub module intended to be used by a queuing server, and a posts and comments modules
|
||||
We'll create 4 modules, a user module (manage user's registration, login, password lost, profile edit and maybe Third party Login/Registration) an emails module intended to be used by a queuing server, and a posts and comments modules
|
||||
|
||||
## Config
|
||||
`run.py` will be used to launch the web server.
|
||||
|
|
@ -169,7 +169,7 @@ and it's constants in the `constants.py` file:
|
|||
ACTIVE: 'active',
|
||||
}
|
||||
|
||||
First about the constants file, I like to have my constants in its own file and inside my module for 2 main reasons. You're constants will probably be used in your models, forms and views. The second reason is that it's a better organization for you to find them. Also, importing your constants as the module in uppercase indicate the constant type and the module name (like USER for users.constants) will avoid you name conflicts.
|
||||
First about the constants file, I like to have my constants their own file and inside my module for 2 main reasons. Your constants will probably be used in your models, forms and views. The second reason is that it's a better organization for you to find them. Also, importing your constants as the module in uppercase indicate the constant type and the module name (like USER for users.constants) will avoid you name conflicts.
|
||||
|
||||
### First form
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue