ACF Recipes
Final demo site π acfrecipes.wpengine.com
π₯ Slides for this presentation π₯
(This presentation was also created as a CPT and with Pattern Manager π)
Description
A demonstration of using Advanced Custom Fields (ACF) to:
- Create a custom post type:
Recipe
- Create a custom taxonomy:
Recipe Types
(e.g. breakfast, lunch, dinner)
- Create custom fields group: Cook & Prep Times
- Create a custom ACF Block: Cook & Prep Times that utilizes the custom fields and is available for the Recipe custom post type
- Create custom block patterns using WP Engine's Pattern Manager
- Assign the block patterns to the Recipe post type
- Make it available in the Recipe new post modal for editors
- Register a custom block pattern category for Recipes
- Set a custom load & save point for ACF JSON. So we can version control our ACF generated CPT, taxonomy, and field groups directly in our custom plugin:
plugins/acf-cooking-recipes/acf-json
Includes:
- WP Engine's Frost theme with patterns automatically generated and saved to the theme's
/patterns/
directory. Again, created with Pattern Manager, which also saves media (images) alongside each pattern within the theme!
The root of this repo represents the wp-content/
directory of your WordPress install.
All of the content used to populate this learning resource site was sourced from SimplyRecipes.com
Requirements
-
ACF PRO 6.1.0-alpha1 β for ACF stuff.
Optional
-
Pattern Manager 0.1.3 β if you want to create and maintain further patterns, but not necessary if you do not.
-
WordPress Beta Tester 3.2.9 β if you want to run the latest WP 6.2 RC2, which was used in the demo, but WP 6.1 will likely work just fine.
-
Gutena Newsletter 1.1.4 β for newsletter block in footer template part, but you can remove the block and do not need it (your preference).
Resources
Changelog
- March 16, 2023
- Fixed misspelling of demo site
- Add 'Requirements' section in README
- Add
lazyrecipes.WordPress.2023-03-16.xml
WordPress export of Recipes custom post type
- March 15, 2023 β initial push of repo with ACF Cooking Recipes plugin and Frost theme