Summing Up

As we’ve seen, Tornado makes it easy to extend templates so that your web code can be easily reused throughout your application. With the addition of modules, you can make more finegrained decisions on what files, style, and script actions to include. However, while our examples have relied on how easy it is to work with Python’s native data types, it wouldn’t make much sense to hardcode big data structures into your applications in practice. Next, we’ll see how we can tie in persistent storage to deal with storing, serving, and editing dynamic content.

Get Introduction to Tornado now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.