Explore >> Select a destination


You are here

sobolevn.me
| | bluebones.net
8.3 parsecs away

Travel
| |
| | aaronluna.dev
16.5 parsecs away

Travel
| | Decorators can be a daunting topic when first encountered. While the Zen of Python states "There should be one- and preferably only one -obvious way to do it", there are many, equally valid ways to implement the same decorator. These different methods can be categorized as either function-based, class-based, or a hybrid of both. In this post I will explain the design and behavior of Python decorators and provide examples of decorators that I frequently use in my own code.
| | www.pmatiello.me
9.2 parsecs away

Travel
| | Implementing interface contracts in Python with class decorators
| | ericlathrop.com
103.5 parsecs away

Travel
| I often need to view a bunch of static HTML files in my browser locally, and I often need to open them with http:// rather than file:// URLs so related CSS or JavaScript files load correctly. Luckily, Python provides a simple web server, and most Linux distros include Python.