• Overview of django • Dive into Settings File • Take some Notes • Testing your application • Some best practices • Example Repo [https://github. com/fRuiApps/djbp]
Path ◦ no hardcoded paths eg. /home/betaversion/... • Keep secret keys Secret • Different Settings for different environment • Custom Middlewares & ContextProcessors in a try catch block • local_settings.py is an AntiPattern
should be names as first_name and NOT FirstName. ◦ The database table names(class names) should be named as ClassNames and not class_names ◦ There should be a unicode method for each of the classes.
the project level, and one base. html at each of the app levels. ◦ App level base.html should extend the project level base.html ◦ The variable in templates should have spaces between the name and bracket. Eg. {{ variable }} and NOT {{variable}}
▪ use slugs instead of primary keys ◦ Each of the urls should have a name, corresponding to the view name. ◦ There should be one urls.py at the project level, and one urls.py at each app level. The project level urls. py should include each of the urls.py under a prefix. Further Reading