RESTful and HTTP APIs in Pyramid Transcripts
Chapter: Conclusion
Lecture: Lightning review: Web building blocks

Login or purchase this course to watch this video and the rest of the course contents.
0:01 Okay, next we came to web building blocks in pyramid.
0:03 So we saw that first thing we had to do is create a route
0:06 and we did this in the dunder init, in the main method there
0:11 and we said we have to set up patterns, not regular expressions,
0:14 like some frameworks with just patterns with little template holes in them, if you will
0:18 and we're going to map those over to views.
0:21 Views sometimes known as controllers in the nvc world,
0:24 these are the things that process our requests
0:27 and decide what to send back if anything at all;
0:29 templates, these are the dynamic html views that sometimes we send back,
0:33 this was the home page, this was the doc page, things like that.
0:36 Models, we had several levels of models, the actual thing we return
0:40 were often— often, not always, Python dictionaries
0:44 unless we configure the renderers to treat special types that it knows about.
0:49 But, we also had view models in there,
0:51 which served a slightly different role than the models typically talked about here.
0:54 Static types and static files right, so css, javascript, images,
0:59 we saw that we can map a special part of our web application
1:03 to serve up files and no other part of will.
1:06 We also did a lot with configuration,
1:08 in the beginning we just played with development.ini,
1:11 but as we got to deployment, we saw that the production.ini
1:14 and the ability to have different configurations
1:17 for locally running our code versus running in production,
1:19 turns out to be super helpful.