Who is this session for?
Content, Developer, UX
Session description
When we at St. Olaf began the move to Gutenberg blocks, we quickly realized the need to decrease the number of blocks available to our site admins. Using the UI, or even something more programmatic, still fell short of what we needed in terms of scope and flexibility. We wanted control over not only core blocks, but block variations, ACF blocks from our theme, and blocks introduced by 3rd party plugins.
In this session, I’ll break down our approach to developing a centralized plugin that lists all currently-registered blocks, updating as plugins are activated and deactivated. This approach provides our end-users with a slim, curated block inserter, while allowing our 2-person web team complete, network-level control over which blocks to show and hide.
Attendees will see an example of the plugin in action, and then we’ll delve into the code to learn about some hooks provided by WordPress that came in particularly handy, and see how we incorporated them into our plugin.
I’ll also highlight some challenges and pitfalls — from navigating the loading sequence to updating network settings via the Settings API — so those wishing to use a similar approach will know where to start, and what to avoid.
Presenter
Bret Farley
Bret is a web developer at St. Olaf College, where he builds custom blocks, plugins, and other random apps to support their WordPress multisite and theme. He has worked in higher education for 5 years, initially employed at Carleton College (the other liberal arts college in Northfield, MN) to lead the migration of their content over to WordPress. An Enneagram 5 to the core, he enjoys solitude and any project challenging enough to turn his brain into a pretzel.
Before his current career, he worked as an animator for commercial and medical animation, a stay-at-home parent, and a bookseller (mainly to be surrounded by books). In his off time, he enjoys dabbling in personal coding projects and writing short fiction.
Sessions
- General Lecture Session: Block Less, Smile More: How St. Olaf College Cracked the Block-Hiding Code