Theme Handbook Recipes

Below are recipes showing how to use the SUFramework theme API. These recipes are intended to be a jumping-off point for people who are interested in experimenting with the APIs for themselves.

Many of these recipes make use of custom collections. You’ll need to set up your own custom collections to make full use of the recipe. For more information on custom collections and links to a few more-detailed step-by-step recipes, please see the page What is a Collection? on the SimpleUpdates support website.

In addition, you’ll probably also find it useful to reference the Twig API docs for more detailed information on everything the SUFramework Twig API has to offer, as well as the official Twig Documentation.

Accordion

See the Pen Accordion by Narthur (@narthur) on CodePen.

su-narthur/videos.twig

Display three YouTube videos on your home page from your media manager, filtered by tag.

su-narthur/devotional_recipe.twig

Display devotionals from a devotional custom collection.

su-narthur/sunset_times.twig

Display sunset times.

su-narthur/testimonial_carousel.twig

Display testimonials from a custom collection.

su-narthur/directory_recipe.twig

Create a directory listing using a custom collection.

su-narthur/ivy_faculty_listing.twig

A version of this code generates the faculty listing in the Ivy theme.

su-narthur/devotional_block.twig

Another take on using a custom collection to display devotionals.

su-narthur/recentPostsWidget.twig

Create your own recent posts widget.