Skills Expanded

Add Extensions to a Static Site Generator with Python

What you'll learn

Python is great for building simple command line applications. In this project you’ll use function decorators to architect an extension system.

Table of contents

Setup
15m
  • Set up your local environment for this project. We'll walk you through everything you need to know, including how to install and configure your environment to be able to complete all of the tasks.
Load Extensions
15m
  • In this module we'll put in place an architecture to dynamically load modules as extensions. These functions will allow loading all extensions from a directory.
Event and Filter Hooks
15m
  • In this module we'll create a function decorator that can register two different types of hooks. Extension events will fire functions. Extension filters will fire functions, as well as capture results.
Menu Extension
15m
  • In this module we'll create an extension that will automatically generate the HTML for a menu. This menu will be injected when each Markdown or ReStructedText file is converted to HTML.
Stats Extension
10m
  • In this module we'll create an extension that will calculate and report several statics. These statics will include total files converted and average time to convert.

About the author

Tom is a staff author at Pluralsight helping to develop Hands-On content. Tom's background in software development, UI/UX, and instructional design was developed over the years while working as a faculty member at the School of Computing at Weber State University in Utah, and continues to grow as he develops Projects and Labs for Pluralsight. When he's not creating content to allow learners to gain real-life experience, he enjoys spending time with his family.

Ready to upskill? Get started