• All
  • Joomla.org Announcements
  • Joomla.org Community
  • Kevin Muldoon
  • TechRadar News
  • TechRadar Reviews
  • Ultranet Domains Hosting Blog
  • Unclassified
  • Web Technology
  • WordPress News
  • WordPress Plugins
  • WordPress Themes
Web Technology, WordPress News

5 Time-Saving WordPress Block Editor Tips and Tricks

From List View to keyboard shortcuts to the powerful Command Palette, the WordPress Block Editor is loaded with time-saving tricks that will streamline your workflows and ensure that you’re operating at peak efficiency. In this Build and Beyond video, Jamie Marsland shows us his five favorite WordPress Block Editor time savers.

Ready to get going? Start your free trial today:

Web Technology, WordPress News

How to Add Smooth Scrolling Anchor Links to Your Website

An “anchor” link is a link that takes readers to a specific spot on the same page (rather than taking them to a new page altogether). It’s like a shortcut. In most cases, clicking that link brings readers to the desired place with an abrupt jump. In today’s Build and Beyond video, Jamie Marsland shows you how to make that transition a smooth scroll instead of a jump, making for a more pleasant reading and browsing experience.

Ready to get going? Start your free trial today:

Web Technology, WordPress News

Introducing Scheduled Updates: Tailored Plugin Management for Your Website

In recent weeks, we’ve announced a few new tools for developers that make WordPress.com the best place to build any WordPress site: Studio local dev app, GitHub Deployments, improved navigation and user interface, and more. 

Today, we’re continuing the streak with our latest feature: scheduled updates for plugins. 

Say goodbye to the hassle of manual updates because streamlined plugin management tools are here and designed to elevate your site’s reliability and performance.

Plugin updates on your terms 

With our newly launched scheduled updates, you can set the exact time and day for updates to occur, ensuring they happen when it’s most convenient for you and your clients. Best of all, this feature is free to use on our Creator and Entrepreneur plans. We won’t name names, but update scheduling is often a paid add-on at other hosts. 

At the selected time, our system automatically checks for available updates for the plugins included in your schedule. If updates are available, the system initiates the process, starting with a health check to ensure your site’s stability. Each plugin is updated individually, with another health check performed after each update to verify everything is functioning as expected.

Should a health check fail, our system will automatically roll back the update and restore the previous version. In the rare event that a rollback is unsuccessful, our dedicated Happiness Engineers are standing by to manually restore your site and assist you further.

To stay on top of what’s running in the background, you can opt to receive an email notification after each scheduled update summarizing the plugins that were updated as well as any update or health check failures. (These emails aren’t sent if no updates are found.) Additionally, you can easily monitor the results of the most recent schedule run on the Scheduled Updates screen under Plugins → Scheduled Updates.

Why does it matter?

Let’s say you run an ecommerce store on WordPress.com. Your site relies on key plugins for inventory management and payment processing. In the past, updating plugins during business hours could lead to downtime and potentially lost sales. With scheduled updates, you can now plan updates for off-peak hours, when you’re at home restfully sleeping, ensuring essential functionality remains intact during busy periods while keeping your site secure and up-to-date. Scheduling updates for your payment processing plugin to occur every Sunday at 2:00 AM will greatly minimize shoppers’ disruptions.

Why our scheduled updates are better

No additional charge: Scheduled updates are included with our Creator and Entrepreneur plans at no extra cost. 

Multiple schedules: Create separate schedules for different plugins, offering greater flexibility and control compared to competitors.

Specific scheduling: Schedule updates at a specific hour for precise timing control.

Customizable health check paths: Specify custom paths for health checks and testing on a per-site basis, providing unparalleled flexibility. 

Granular schedule pausing: Pause individual update schedules for targeted control, a feature not offered by other hosts.

Detailed logging: Comprehensive logging of update activities, including successes, failures, and rollbacks, ensures transparency and accountability.

Faster setup: Our setup process is lightning-fast, with no need for extra information collection or onboarding.

How to get started

Creating a schedule for plugin updates is fast and convenient:

Install your desired plugins on a Creator or Entrepreneur site. (Plugins included in our plan offerings or purchased through the WordPress.com Marketplace are kept up-to-date by WordPress.com and do not need to be scheduled.)

Navigate to the Updates Manager: Plugins → Scheduled Updates. (Click here to visit the multisite update manager.)

Click “Add new schedule” and select your desired update frequency.

Choose the plugins you’d like to include in the schedule.

Click “Create” to activate your schedule.

For more details, visit our Update a Plugin or Theme support page.

Take control of your plugin updates 

Click here to get started with a free hosting trial and experience the peace of mind that comes with scheduled updates.

Stay tuned for more enhancements coming soon, including the ability to create update schedules for multiple sites at once and many more features.

Web Technology, WordPress News

3 Ways for WordPress Devs, Agencies, and Freelancers to Prepare for 2025 

It may be hard to believe, but we’re nearly halfway through 2024, which means it’s not too early to start thinking ahead to next year. In this Build and Beyond video, Jamie Marsland speaks with Nick Diego, a Developer Relations Advocate and Core Contributor at WordPress.org, about ensuring you’re prepared for the exciting developments in store for WordPress in 2025. 

Ready to get going? Click below to embark on your free trial today:

Best Free themses for Wordpress
WordPress News

Hot Off the Press: New WordPress.com Themes for May 2024

The WordPress.com team is always working on new design ideas to bring your website to life. Check out the latest themes in our library, including great options for bloggers, visual designers, and art aficionados.

Fewer

Fewer is perfect for showcasing portfolios and blogs. With a clean, minimalist design, it offers excellent typography and style variations that make it easy to present your work or business. Fewer is highly versatile, offering a range of customizable options that allow you to tailor your site to your exact needs.

Click here to view a demo of this theme.

Ron

Ron is a theme that’s laser-focused on delivering an exceptional reading experience. It’s set apart by its offset post layout and sticky navigation. We’ve also intentionally omitted a header, allowing readers to dive straight into the content without distractions.

Click here to view a demo of this theme.

Texty

Texty isn’t just another blog theme, it’s a celebration of pure, unadulterated storytelling. This theme dances to its own beat by relying entirely on post excerpts on the homepage to captivate and intrigue. A remix of the beloved Issue theme, Texty can also bring a burst of color to your blogging with its vibrant variations in blue, maroon, burgundy, and neon green. Whether you’re sharing tales of adventure, pouring out your thoughts, or spinning poetry, this theme provides the perfect backdrop for your journey. Let your creativity run wild and let your words shine, because with Texty, your stories are the stars of the show.

Click here to view a demo of this theme.

Fontaine

Fontaine is a dynamic portfolio and personal profile theme that celebrates minimalist design and Brutalist aesthetics. Created especially with visual designers in mind, Fontaine gracefully steps back, allowing your work to shine and captivate your audience. With a strikingly simple yet dynamically elegant design, Fontaine’s dramatic font scale and transparent header (check out the demo to see this in action!) blend seamlessly to create compelling contrasts and modern sophistication. At its heart, Fontaine invites you to showcase your work and share your story with confidence.

Click here to view a demo of this theme.

Surrealist

Inspired by the iconic art movement, Surrealist merges clarity with a touch of whimsy, capturing the essence of Surrealism in every pixel. In our font pairing of PT Sans with Kame, we’ve set the tone for an immersive, delight-inducing experience.

As you navigate the front page, you’ll encounter the statement-making site title, inviting you to explore further into the quirky atmosphere of Surrealist. With distinctive design treatments and blocks that spark the imagination, Surrealist invites you to unleash your creativity and embark on a journey of self-expression.

Click here to view a demo of this theme.

To install any of the above themes, click the name of the theme you like, which brings you right to the installation page. Then click the “Activate this design” button. You can also click “Open live demo,” which brings up a clickable, scrollable version of the theme for you to preview.

Premium themes are available to use at no extra charge for customers on the Explorer plan or above. Partner themes are third-party products that can be purchased for $99/year each on the Creator plan and above.

You can explore all of our themes by navigating to the “Themes” page, which is found under “Appearance” in the left-side menu of your WordPress.com dashboard. Or you can click below:

WordPress News, Web Technology

How to Build Man. United’s Grid Layout Homepage

<div class="wp-block-embed__wrapper">
<div class="jetpack-video-wrapper"></div>
</div>
<p>Manchester United currently stand eighth in the table, but at least they have a beautiful card layout on their website. In today’s Build and Beyond video, <a href="https://www.pootlepress.com/about-pootlepress/">Jamie Marsland</a> attempts to build this unique layout using WordPress.com. </p>
<p>Grid functionality is coming to <a href="https://make.wordpress.org/core/2024/05/03/roadmap-to-6-6/">WordPress 6.6</a>, but it’s actually available on WordPress.com right now. Test it out, and let us know what you think.</p>
<p>Ready to get going? Click below to embark on your free trial today:</p>
<div class="wp-block-buttons is-layout-flex wp-block-buttons-is-layout-flex">
<div class="wp-block-button btn-primary"><a class="wp-block-button__link has-white-color has-text-color has-link-color wp-element-button" href="http://wordpress.com/jamie">WordPress.com/Jamie</a></div>
</div>
Web Technology, WordPress News

The Best Way to Quickly Build a Beautiful WordPress Website

There’s no better way to quickly build a WordPress website than with patterns, whether you’re a seasoned pro using patterns to quickly mock up wireframes or a dabbling hobbyist using them for your finished product. In today’s Build and Beyond video, Jamie Marsland shows you how to use patterns to build your site with WordPress blocks.

Ready to get going? Click below to embark on your free trial today:

Web Technology, WordPress News

Font Freedom: Unleash Creative Typography on Your WordPress.com Site

A website speaks to its visitors not only through its content and imagery, but also with its typography. A carefully selected font can set the site’s tone, convey emotion, and leave a lasting impression. 

With the new Font Library on WordPress.com, you can now upload custom typography without the hassle of coding or the limitations of plugins. It’s not just about choosing fonts; it’s about effortlessly crafting an experience for your visitors. 

Available on WordPress.com sites with the Creator or Entrepreneur plan, the Font Library allows you to manage your site’s typography in one place. Installing, removing, and activating or deactivating fonts across your entire site is a breeze. 

To access the Font Library, head to the Site Editor and open the “Styles” side panel. Once there, select “Typography” and select the settings icon next to the “Fonts” heading.

Once in the Font Library, you will see the list of available fonts for your site: those that come with your theme, as well as any custom fonts you have installed. 

There are two ways to install fonts: 

Manually upload the font files from the “Upload” tab

Connect to Google Fonts on the “Install Fonts” tab, then download any selected fonts to your site

In addition to this high-level customization, the Font Library also provides granular control of the font weights that you’d like to enable, minimizing the effects on site speed because it’s only what you need that’s being loaded. 

Level up your site by adding that extra touch of typography personality by using the Font Library, no code or plugins needed. To learn more, check out the support article

WordPress News

The Top 5 AI-Powered Tools for WordPress Creatives

While AI tools offer great potential to streamline our creative processes, their proliferation has made it hard to know which specific tools are useful and which are more showy than practical. In today’s Build and Beyond video, Jamie Marsland walks us through his five favorite AI-powered tools, including text-to-speech software, the best image generator on the market, and a great overview of Jetpack’s built-in AI Assistant.

Ready to get going? Click below to embark on your free trial today:

Here are AI-powered tools mentioned in the video:

Fontjoy

Generate font combinations with the click of a button.

Relume

From site description to an optimized sitemap in seconds.

Adobe Firefly

The best, most powerful image generator on the market.

Elevenlabs

Incredible text-to-speech conversion.

Jetpack AI Assistant

Powerful text creation and editing, built right into WordPress.com.

Ultranet Domains Hosting Blog, WordPress News

Hot Off the Press: New WordPress.com Themes for April 2024

The WordPress.com team is always working on new design ideas to bring your website to life. Check out the latest themes in our library, including great options for minimalist bloggers, retailers, and creatives of all stripes.

Alter

Alter is a lean theme for bloggers that gets directly to the point, showing text-only posts right above the fold ornamented by a single image. The bold default color scheme plays against the minimalist content design for a fun and surprising aesthetic. And, of course, you can always change those default styles if pink and purple aren’t your thing.

Click here to view a demo of this theme.

Swag

As you might have gathered from the name of this sharp new theme, Swag is built with product sales in mind from the very start. This theme boasts a minimalist design aesthetic, ensuring your products take center stage. While Swag is perfect for fashion boutiques, its versatility knows no bounds. Whether you’re selling apparel, accessories, or even digital goods, this theme provides the perfect canvas for your unique brand identity.

Built with WooCommerce compatibility at its core, Swag ensures a seamless shopping experience for your customers. From product pages to checkout, every step is optimized for maximum conversion.

Click here to view a demo of this theme.

Stage

Stage is where artistic expression meets simplicity and is a new go-to WordPress.com theme for artists and creatives. Its simple yet powerful interface allows for easy content organization, while the elegant two-column grid layout beautifully highlights your work. With seamless mobile responsiveness and a focus on readability, Stage lets your creativity take center stage (sorry, we just had to!).

Powered by the Inter Tight font and a subtle duotone color palette, this theme exudes authenticity and raw creativity. Personalize your site effortlessly with included color variations.

Click here to view a demo of this theme.

Roam

Roam invites bloggers, travelers, and creatives to embark on a seamless journey of storytelling. With its captivating full-page cover photo and sleek one-column layout, Roam offers a canvas for your unique voice and vision. Tailor your blog effortlessly with customizable fonts, colors, and layouts and let your best work shine with Roam’s featured article showcase. Built-in SEO optimization ensures global visibility and searchability.

Click here to view a demo of this theme.

Boxed Bio

Boxed Bio heralding a new era of dynamic expression in the “link in bio” category of themes. Through an artful arrangement of column blocks adorned in vibrant hues and captivating images, Boxed Bio transforms simple links into enduring and inspiring narratives. With its three column groups, each a canvas for visual storytelling, and jazzy typography choices this invites you to unleash your creativity. These aren’t just links, after all, they are doorways to possibility.

Click here to view a demo of this theme.

To install any of the above themes, click the name of the theme you like, which brings you right to the installation page. Then click the “Activate this design” button. You can also click “Open live demo,” which brings up a clickable, scrollable version of the theme for you to preview.

Premium themes are available to use at no extra charge for customers on the Explorer plan or above. Partner themes are third-party products that can be purchased for $79/year each.

You can explore all of our themes by navigating to the “Themes” page, which is found under “Appearance” in the left-side menu of your WordPress.com dashboard. Or you can click below:

WordPress News, Ultranet Domains Hosting Blog

Meet Studio: Your New Favorite Way to Develop WordPress Locally

Say goodbye to manual tool configuration, slow site setup, and clunky local development workflows, and say hello to Studio by WordPress.com, our new, free, open source local WordPress development environment.

We’ve built Studio to be the fastest and simplest way to build WordPress sites locally.

Designed to empower developers, designers, and site builders, Studio offers a seamless solution for creating and running WordPress sites directly on your local machine, as well as showcasing work-in-progress sites with your clients, teams, and colleagues.

Check out a few of our favorite features in the video below:

A new way to develop WordPress locally, available for free

Studio is now available to use for free on Mac*, and you can get up and running with a new local site in just a few minutes:

Download Studio for Mac.

Install and open Studio.

Click Add site, and you’re done!

Once you have a local site running, you can access WP Admin, the Site Editor, global styles, and patterns, all with just one click—and without needing to remember and enter a username or password.

You can even open your local sites in your favorite development tools, such as VS Code, PhpStorm, Terminal, and Finder, making it even easier to add Studio to your existing development workflow.

Plus, Studio is open source; feel free to fork away on GitHub.

*A Windows version of Studio is coming soon, and you can request early access here

Effortlessly share your work and keep moving forward

In the realm of web development, showcasing local work has often been a challenge when projects live solely on your machine. With Studio’s demo sites, you have a convenient, built-in solution for sharing your progress with your team, clients, or designers. 

These publicly-accessible demo sites, hosted on WordPress.com, are a convenient way to share your work without the need for complex server setups or lengthy deployments. In less than 15 seconds, you can have a shareable link to your local site that stays active for seven days.

The best part? Demo sites can be refreshed to reflect your latest build, allowing you to easily convey any updates or changes!

Breaking free from traditional constraints

Unlike traditional local environment tools like MAMP or Docker, Studio takes a fresh approach to local WordPress development. Studio is a lightweight and efficient solution that minimizes overhead and maximizes simplicity by forgoing the need for web servers, MySQL servers, or virtualization technologies.

Behind the scenes, Studio uses WordPress Playground, the WebAssembly-powered PHP binary. Thanks to this technology, there is no need to use a traditional web server, making your development experience much quicker and smoother.

Say goodbye to complex setups and compatibility issues. Studio makes it easier than ever to build and manage WordPress sites locally.

Let’s get building

At WordPress.com, we’re committed to making your website management experience seamless. In the last few years alone, we launched staging sites with synchronization features, SSH and WP-CLI access, global edge caching, GitHub Deployments, and more. 

Studio is yet another powerful feature to add to your toolkit. Stay tuned for more exciting updates, and remember to follow our blog to stay in the loop.

And, of course, download Studio today. Your local development workflow will thank you.

Major kudos to the Studio team on this launch! Antonio Sejas, Antony Agrios, Kateryna Kodonenko, Philip Jackson, Carlos García Prim, David Calhoun, Derek Blank, Siobhan Bamber, Tanner Stokes, Matt West, Adam Zielinski, Brandon Payton, Berislav Grgicak, Alexa Peduzzi, Jeremy Massel, Gio Lodi, Olivier Halligon, Matthew Denton, Ian Stewart, Daniel Bachhuber, Kei Takagi, Claudiu Filip, Niranjan Uma Shankar, Noemí Sánchez, and our beta testers.

Ultranet Domains Hosting Blog, WordPress News

WordPress Block Patterns Give You Superpowers

With the power of block patterns you’ll be a WordPress superstar in no time, whether you’re an establish pro or just starting out. Block patterns are professionally designed layouts that you can add your site in a single click. What makes them especially powerful is that once they’re inserted, you can edit and customize every aspect. (Or, you can leave them be!)

In today’s Build and Beyond video, Jamie Marsland walks you through everything you need to go to become a block pattern expert, in under four minutes.

Get started on your site today with a free trial:

Ultranet Domains Hosting Blog, WordPress News

10 Amazing WordPress Design Resouces

Designing a beautiful website from scratch can be difficult for developers of all skill levels. Luckily, in today’s Build and Beyond video, Jamie Marsland reveals his ten favorite WordPress design tools and websites to elevate your next build.

Get inspiration for your next website’s design and then start building with WordPress.com. Ready to get going? Click below to embark on your free trial today:

Here are the sites and resources mentioned in the video:

Heikei

Stunning backgrounds and visuals

WordPress.com Assembler

A design-your-own-theme tool using block patterns

Glassmorphism

Free CSS generator for a glass effect

Designspiration

Save and explore inspiring designs

Shots

Easy mockups for products and thumbnails

WordPress.com Pattern Library

WordPress.com’s free library of block patterns

Coolors

Generate color palettes with a click

WordPress.org Pattern Library

Another block pattern library, but with community-uploaded designs

Midjourney

The best AI image generator

Instant Images

WordPress plugin to easily find free-to-use images

Ultranet Domains Hosting Blog, WordPress News

Making 43% of the Web More Dynamic with the WordPress Interactivity API

Creating rich, engaging, and interactive website experiences is a simple way to surprise, delight, and attract attention from website readers and users. Dynamic interactivity like instant search, form handling, and client-side “app-like” navigation where elements can persist across routes, all without a full page reload, can make the web a more efficient and interesting place for all.

But creating those experiences on WordPress hasn’t always been the easiest or most straightforward, often requiring complex JavaScript framework setup and maintenance. 

Now, with the Interactivity API, WordPress developers have a standardized way for doing that, all built directly into core. 

The Interactivity API started as an experimental plugin in early 2022, became an official proposal in March 2023, and was finally merged into WordPress core with the release of WordPress 6.5 on April 2, 2024. It provides an easier, standardized way for WordPress developers to create rich, interactive user experiences with their blocks on the front-end.

ELI5: The Interactivity API and the Image Block

Several core WordPress blocks, including the Query Loop, Image, and Search blocks, have already adopted the Interactivity API. The Image block, in particular, is a great way to show off the Interactivity API in action. 

At its core, the Image blocks allow you to add an image to a post or page. When a user clicks on an image in a post or page, the Interactivity API launches a lightbox showing a high-resolution version of the image.

The rendering of the Image block is handled server-side. The client-side interactivity, handling resizing and opening the lightbox, is now done with the new API that comes bundled with WordPress. You can bind the client-side interactivity simply by adding the wp-on–click directive to the image element, referencing the showLightbox action in view.js.

You might say, “But I could easily do this with some JavaScript!” With the Interactivity API, the code is compact and declarative, and you get the context (local state) to handle the lightbox, resizing, side effects, and all of the other needed work here in the store object.

actions: {
showLightbox() {
const ctx = getContext();

// Bails out if the image has not loaded yet.
if ( ! ctx.imageRef?.complete ) {
return;
}

// Stores the positons of the scroll to fix it until the overlay is
// closed.
state.scrollTopReset = document.documentElement.scrollTop;
state.scrollLeftReset = document.documentElement.scrollLeft;

// Moves the information of the expaned image to the state.
ctx.currentSrc = ctx.imageRef.currentSrc;
imageRef = ctx.imageRef;
buttonRef = ctx.buttonRef;
state.currentImage = ctx;
state.overlayEnabled = true;

// Computes the styles of the overlay for the animation.
callbacks.setOverlayStyles();
},

The lower-level implementation details, like keeping the server and client side in sync, just work; developers no longer need to account for them.

This functionality is possible using vanilla JavaScript, by selecting the element via a query selector, reading data attributes, and manipulating the DOM. But it’s far less elegant, and up until now, there hasn’t been a standardized way in WordPress of handling interactive events like these.

With the Interactivity API, developers have a predictable way to provide interactivity to users on the front-end. You don’t have to worry about lower-level code for adding interactivity; it’s there in WordPress for you to start using today. Batteries are included.

How is the Interactivity API different from Alpine, React, or Vue?

Prior to merging the Interactivity API into WordPress core, developers would typically reach for a JavaScript framework to add dynamic features to the user-facing parts of their websites. This approach worked just fine, so why was there a need to standardize it?

At its core, the Interactivity API is a lightweight JavaScript library that standardizes the way developers can build interactive HTML elements on WordPress sites.

Mario Santos, a developer on the WordPress core team, wrote in the Interactivity API proposal that, “With a standard, WordPress can absorb the maximum amount of complexity from the developer because it will handle most of what’s needed to create an interactive block.”

The team saw that the gap between what’s possible and what’s practical grew as sites became more complex. The more complex a user experience developers wanted to build, the more blocks needed to interact with each other, and the more difficult it became to build and maintain sites. Developers would spend a lot of time making sure that the client-side and server-side code played nicely together.

For a large open-source project with several contributors, having an agreed-upon standard and native way of providing client-side interactivity speeds up development and greatly improves the developer experience.

Five goals shaped the core development team’s decisions as they built the API: 

Block-first and PHP-first: Prioritizing blocks for building sites and server side rendering for better SEO and performance. Combining the best for user and developer experience.

Backward-compatible: Ensuring compatibility with both classic and block themes and optionally with other JavaScript frameworks, though it’s advised to use the API as the primary method. It also works with hooks and internationalization.

Declarative and reactive: Using declarative code to define interactions, listening for changes in data, and updating only relevant parts of the DOM accordingly.

Performant: Optimizing runtime performance to deliver a fast and lightweight user experience.

Send less JavaScript: Reduce the overall amount of JavaScript being sent on the page by providing a common framework that blocks can reuse.  So the more that blocks leverage the Interactivity API, the less JavaScript will be sent overall.

Other goals are on the horizon, including improvements to client-side navigation, as you can see in this PR.

Interactivity API vs. Alpine

The Interactivity API shares a few similarities to Alpine—a lightweight JavaScript library that allows developers to build interactions into their web projects, often used in WordPress and Laravel projects.

Similar to Alpine, the Interactivity API uses directives directly in HTML and both play nicely with PHP. Unlike Alpine, the Interactivity API is designed to seamlessly integrate with WordPress and support server-side rendering of its directives.

With the interactivity API, you can easily generate the view from the server in PHP, and then add client-side interactivity. This results in less duplication, and its support in WordPress core will lead to less architectural decisions currently required by developers. 

So while Alpine and the Interactivity API share a broadly similar goal—making it easy for web developers to add interactive elements to a webpage—the Interactivity API is even more plug-and-play for WordPress developers.

Interactivity API vs. React and Vue

Many developers have opted for React when adding interactivity to WordPress sites because, in the modern web development stack, React is the go-to solution for declaratively handling DOM interactivity. This is familiar territory, and we’re used to using React and JSX when adding custom blocks for Gutenberg.

Loading React on the client side can be done, but it leaves you with many decisions: “How should I handle routing? How do I work with the context between PHP and React? What about server-side rendering?”

Part of the goal in developing the Interactivity API was the need to write as little as little JavaScript as possible, leaving the heavy lifting to PHP, and only shipping JavaScript when necessary.

The core team also saw issues with how these frameworks worked in conjunction with WordPress. Developers can use JavaScript frameworks like React and Vue to render a block on the front-end that they server-rendered in PHP, for example, but this requires logic duplication and risks exposure to issues with WordPress hooks.

For these reasons, among others, the core team preferred Preact—a smaller UI framework that requires less JavaScript to download and execute without sacrificing performance. Think of it like React with fewer calories.

Luis Herranz, a WordPress Core contributor from Automattic, outlines more details on Alpine vs the Interactivity API’s usage of Preact with a thin layer of directives on top of it in this comment on the original proposal.

Preact only loads if the page source contains an interactive block, meaning it is not loaded until it’s needed, aligning with the idea of shipping as little JavaScript as possible (and shipping no JavaScript as a default).

In the original Interactivity API proposal, you can see the run-down and comparison of several frameworks and why Preact was chosen over the others.

What does the new Interactivity API provide to WordPress developers?

In addition to providing a standardized way to render interactive elements client-side, the Interactivity API also provides developers with directives and a more straightforward way of creating a store object to handle state, side effects, and actions.

Graphic from Proposal: The Interactivity API – A better developer experience in building interactive blocks on WordPress.org

Directives

Directives, a special set of data attributes, allow you to extend HTML markup. You can share data between the server-side-rendered blocks and the client-side, bind values, add click events, and much more. The Interactivity API reference lists all the available directives.

These directives are typically added in the block’s render.php file, and they support all of the WordPress APIs, including actions, filters, and core translation APIs. 

Here’s the render file of a sample block. Notice the click event (data-wp-on–click=”actions.toggle”), and how we bind the value of the aria-expanded attributes via directives.

<div
<?php echo get_block_wrapper_attributes(); ?>
data-wp-interactive=”create-block”
<?php echo wp_interactivity_data_wp_context( array( ‘isOpen’ => false ) ); ?>
data-wp-watch=”callbacks.logIsOpen”
>
<button
data-wp-on–click=”actions.toggle”
data-wp-bind–aria-expanded=”context.isOpen”
aria-controls=”<?php echo esc_attr( $unique_id ); ?>”
>
<?php esc_html_e( ‘Toggle’, ‘my-interactive-block’ ); ?>
</button>

<p
id=”<?php echo esc_attr( $unique_id ); ?>”
data-wp-bind–hidden=”!context.isOpen”
>
<?php
esc_html_e( ‘My Interactive Block – hello from an interactive block!’, ‘my-interactive-block’ );
?>
</p>
</div>

Do you need to dynamically update an element’s inner text? The Interactivity API allows you to use data-wp-text on an element, just like you can use v-text in Vue.

You can bind a value to a boolean or string using wp-bind– or hook up a click event by using data-wp-on–click on the element. This means you can write PHP and HTML and sprinkle in directives to add interactivity in a declarative way.

Handling state, side effects, and actions

The second stage of adding interactivity is to create a store, which is usually done in your view.js file. In the store, you’ll have access to the same context as in your render.php file.

In the store object, you define actions responding to user interactions. These actions can update the local context or global state, which then re-renders and updates the connected HTML element. You can also define side effects/callbacks, which are similar to actions, but they respond to state changes instead of direct user actions.

import { store, getContext } from ‘@wordpress/interactivity’;

store( ‘create-block’, {
actions: {
toggle: () => {
const context = getContext();
context.isOpen = ! context.isOpen;
},
},
callbacks: {
logIsOpen: () => {
const { isOpen } = getContext();
// Log the value of `isOpen` each time it changes.
console.log( `Is open: ${ isOpen }` );
},
},
} );

Try it out for yourself

The Interactivity API is production-ready and already running on WordPress.com! With any WordPress.com plan, you’ll have access to the core blocks built on top of the Interactivity API. 

If you want to build your own interactive blocks, you can scaffold an interactive block by running the below code in your terminal:

npx @wordpress/create-block@latest my-interactive-block –template @wordpress/create-block-interactive-template 

This will give you an example interactive block, with directives and state handling set up. 

You can then play around with this locally, using wp-env, using a staging site, or by uploading the plugin directly to your site running a plugin-eligible WordPress.com plan

If you want a seamless experience between your local dev setup and your WordPress.com site, try using it with our new GitHub Deployments feature! Developing custom blocks is the perfect use case for this new tool.

The best way to learn something new is to start building. To kick things off, you may find the following resources a good starting point:

A first look at the Interactivity API

Interactivity API WP Movies demo and demo video

Follow along with this task for improvements coming to the Interactivity API

Block editor reference

Proposal: Interactivity API

GitHub issue for showcase

Ultranet Domains Hosting Blog, WordPress News

WordPress Website Speed Build: The Masters Golf Tournament

Congratulations are in order for Scottie Scheffler, the winner of the 2024 Masters Tournament in Augusta, Georgia! In today’s Build and Beyond video, Jamie Marsland takes on the slightly less intimidating task of re-creating the Masters website as quickly as he can. Can he possibly do it in just 30 minutes?

Along the way, you’ll learn about sticky navigation menus, image overflows and breakouts, card layouts, and more.

Interested in a free trial that allows you to test our all that WordPress.com has to offer? Click below:

Ultranet Domains Hosting Blog, WordPress News

Registering Custom Post Types in the WordPress Admin: Our CloudFest Hackathon Report

With WordPress today you need to use custom code or a plugin to create a custom post type like “Book” or “Member.” This is a popular need, and there are a variety of approaches; however, one challenge is that the end-user experience can be confusing and non-standardized.

A few weeks ago, some Automatticians and I went to the 7th CloudFest Hackathon in Rust, Germany to explore a solution for this. We started hacking on a deeply nerdy project, JSON Schema forms and fields, and ended up with a fascinating approach to an age-old question: What if you could register custom post types and custom fields directly in the WordPress admin?

Forty-eight hours turns an idea into reality

The CloudFest Hackathon is an event that allows developers from around the globe to take ideas and turn them into realities.

During the Hackathon, teams of developers from various content management systems and hosting companies come together to contribute to projects that align with the core principles of the event: the projects must be not-for-profit, interoperable, and open source.

Last year, we worked on a project that allowed us to embed WordPress directly in VS Code. We built the WordPress Playground VS Code extension on top of WordPress Playground. It uses WebAssembly to run WordPress entirely within the browser, and it turned out pretty darn slick

This year, we focused on a JSON Schema Field/Form Renderer. While most of us explored using JSON Schema to dynamically register admin forms and fields, Dennis Snell and Adam Zieliński decided to take the project one step further! They hacked together a plugin that introduced the ability to register custom post types and custom fields directly from the WordPress admin. More notably, everything happens within the block editor—you have to see it to believe it:

This work poses some interesting possibilities for custom post type and custom field implementation because it could fundamentally change the way low- to no-code WordPress users modify their sites.

Naturally, I took the idea to Twitter/X:

Should WordPress let you register custom post types and custom fields from the admin? #CFHack2024

— daniel (@dbchhbr) March 17, 2024

I got quite a range of responses, ranging from “Heck Yes! It should have already been a core feature now. Such an integral part of every other site” to “Admin should only be for content and user management. Everything else should be configured in code and version controllable.”

So why the range in responses? Let’s discuss.

It turned out to be pretty simple

Dennis and Adam built our prototype using the following conventions:

A custom post type wp_data_type holds templates for user-defined data types.

The title of a post in the wp_data_type defines the name of the new data type. The post itself is the rendering template and comprises any set of normal blocks. Names are given to select block attributes within the post, and these names are mapped into the data type.

When creating new posts for the given data type, the locked template is copied from the wp_data_type template, and the block attribute annotations are preserved.

Finally, when rendering the wp_data_type template, the attributes are pulled from the individual post of the given data type and spliced into the template.

The fascinating idea is that we don’t have to think about form fields; blocks already provide a rendering view and a modal editing experience. We can rely on the fundamental way blocks work and use the very same user experience to create custom data types in a way that users are already familiar with when editing a post or a site.

We can provide JSON-LD markup properties to the block editor using our Custom Fields Names block settings.

Custom post types define custom data types, so we use a template to not only define the data type, but also to provide a default rendering template. Each data attribute within a post type has a field where it’s possible to define that field with its JSON-LD property. 

For example, say you had a “Book” custom post type. A few JSON-LD properties you could define using custom fields are:

description

copyrightYear

author

bookEdition

bookFormat

isbn

numberOfPages

We also chose to store a copy of each block attribute in the JSON attributes for that block. Since WordPress can now provide a post-to-JSON function, which merges the extracted attributes with the names assigned in the custom post type template, that template may have changed since the custom post was created. This means that no database migrations are necessary to render an updated version of a post.

The best part? The WordPress infrastructure that already exists (aka Gutenberg!) defines the data type. Because these custom posts are normal posts, and because they adopt the locked template for the data type definition, they are, in fact, renderable on their own! Even if the template has been updated and only the post itself is rendered, it will still display a meaningful representation of the data type as it was when it was created.

While our original Hackathon project was tailored towards developers and UX designers who would love to see a forms and fields API in WordPress, this prototype puts more power in the hands of low- to no-code WordPress users.

It also opens up a world of possibilities for providing a rendering view for any structured data. Imagine uploading a CSV and mapping the column names to block attributes, or connecting to a database or JSON API to map the records in the same way. 

For example, if you had a CSV with business names, addresses, a rating, and a description, we could take that template post and insert a map block, a heading block, a star rating block, and a paragraph block and set the attributes to map to the CSV columns. It’s essentially an instant structured data renderer!

But even if we can define custom post types and fields in the editor, should we, as a WordPress community, consider adding it to core?

The existential question: Should it exist?

Adding this kind of functionality into WordPress core could open up a ton of opportunities for the average WordPress user. Instead of needing to get a developer involved to add a custom post type to their site, a user could simply do it themselves and define the necessary fields and structured data attributes. 

On the other hand, allowing everyday users, who may not have a full grasp of how custom post types and structured data should work, free reign to create these data types themselves could have detrimental effects on the user experience of their websites. Clunky or incorrect implementation of structured data markup could also cause issues with how search engines crawl these sites, causing unintended negative impacts to search traffic.

Not only that, but as of right now, if a custom post type is accidentally deleted, all of the content posted to that custom post type will no longer be accessible through the admin (even though it will still be stored in the database). The user could think they “lost” their data.

Let’s talk about it

What do you think? Are you in favor of giving website owners the ability to change and customize their custom post types and attributes? Or are there some website features that should always require a more technical hand and implementer? 

We’d love to chat with you about your thoughts in the comments below.

For another interesting exploration on a related idea, check out this discussion on GitHub with the core team.

Thanks to Lars Gersmann for leading the JSON Schema project with me and to everyone on the Syntax Errors team: Adam Zieliński, Dennis Snell, Julian Haupt, Michael Schmitz, Anja Lang, Thomas Rose, Marko Feldmann, Fabian Genes, Michael Schmitz, Jan Vogt, Lucisu, Maximilian Andre, Marcel Schmitz, and Milana Cap.

WordPress News

Site-Building Made Simple: Introducing the Public Pattern Library 

When it comes to website-building, WordPress themes set your site up for success by providing stylish, preselected options for fonts, colors, and layouts. Even though themes provide the overall aesthetic, you still need to build out the posts, pages, and templates on your site. That’s where block patterns come in!

The WordPress.com Pattern Library is your new go-to resource for finding any kind of pattern for your beautiful WordPress website. With hundreds of pre-built patterns to choose from across over a dozen categories, you’ll be covered no matter your website’s specific needs. 

What are patterns?

Block patterns are collections of blocks made to work seamlessly with our modern themes. Need an “About” page? Check. A gallery? Check. A testimonial? Check. How about a newsletter? Check. We have just about anything you’ll need. 

Best of all: for each pattern, the fonts, colors, and spacing will adapt to your theme’s settings, making for a cohesive look. Still, patterns aren’t locked or static either—after you’ve added the pattern to your post, page, or template, you can tweak it however you like. 

A tour of the Pattern Library 

This new public Pattern Library allows you to browse, preview, and easily share or implement whichever design speaks your tastes. Let’s take a look around. 

Browse all categories 

If you want to explore the Pattern Library and don’t have anything in particular that you’re looking for, click through each category to spark some ideas. 

Search for what you need 

At the top, you’ll find a fast and easy-to-use search box, allowing you to find exactly what you need. This is a great option if you don’t feel like browsing and want to jump right into a solution for your specific needs. 

Explore page layouts 

Sometimes you just need the components of a post, page, or template: a header, a “Subscribe” box, a store module, etc. Other times, you want to be able to copy and paste an entire page into existence. Scroll down past the categories and you’ll find our full-page patterns for whole pages: About, Blog, Contact, Store, and more. 

Test the mobile responsiveness for each pattern

When looking through the library on a desktop or laptop device, you’ll see a gray vertical bar next to each pattern. That’s a nifty little slider that we’ve built into the library which allows you to see how each pattern responds to different screen sizes. Using your cursor to move the bar to the left, you’ll see what that design looks like on a mobile device; in the middle is where most tablets fall; and scroll back all the way to the right for the desktop/laptop version. 

Copy and paste to your website 

Like what you see? Simply click the blue “Copy pattern” button, open the WordPress.com editor to the post, page, or template you’re working on, and paste the design. It’s that easy. Once inserted, you can customize each block as needed using the right sidebar. 

Your new favorite page-building tool

The Pattern Library is especially useful if you build websites for clients. Each pattern is built to work with any theme that follows our technical standards, speeding up page-building not just for you but also for your clients—all while maintaining the overall style of your theme. 

In concrete terms, this means that our patterns take font, color, and spacing settings from the theme itself rather than using standard presets. This makes it far less likely for a site to break (or just look off) when you—or a client—experiment and make updates. 

Our goal is always to make your life both easier and more beautiful. This new resource does just that. Check out the WordPress.com Pattern Library today to enhance your website-building experience! 

WordPress News

10 WordPress Influencers to Follow in 2024  

Top WordPress Influencers

In this “Build and Beyond” video, Jamie Marsland highlights 10 WordPressers to keep an eye on in 2024. 

A couple of weeks ago, we shared a list of 15 WordPress developers you should follow to stay on top of WordPress development news and tips. This video broadens the scope and features folks worth following, regardless of your role or experience with WordPress. If you’re at all interested in or curious about WordPress, these are folks to pay attention to.

Interested in a free trial that allows you to test our all that WordPress.com has to offer? Click below:

Remkus de Vries

Remkus is a well-known figure in the WordPress community, recognized for his contributions to WordPress development and his overall expertise in web technology.

Website | YouTube

Kevin Geary

Kevin helps digital agency owners, freelancers, and web designers to learn best practices for UX/UI design, development, and CSS.

Website | YouTube

Tyler Moore

Tyler has free video lessons on YouTube that teach people how to create their own professional website without any coding experience.

Website | YouTube

Sabrina Zeidan

Sabrina is a WordPress performance engineer, who’s daily work is to speed up WordPress websites, plugins, and themes.

YouTube

Mike McAlister

Mike is a designer and principal software engineer from the USA. He builds killer products and brands that people love, including the fantastic Ollie WordPress theme.

Website | X (Twitter)

Jonathan Jernigan

Jonathan runs a small web development agency, creates courses, and makes YouTube videos. He started is WordPress-focused YouTube channel in late 2018.

Website | YouTube

Birgit Pauli-Haack

Birgit works as developer advocate for WordPress, curates community voices on Gutenberg Times, and co-hosts the Gutenberg Changelog podcast.

Website | X (Twitter)

David McCan

For the past 20 years David has worked professionally developing websites and in IT management.

Website | Facebook

Paul Charlton

Paul has over 15 years of commercial web design and development experience working on a large range of diverse projects, with clients ranging from start-ups to blue-chip companies.

Website | YouTube

Matt Medeiros

The WP Minute, founded by Matt, is a website dedicated to delivering the most important news and topics from the WordPress ecosystem, keeping WordPress professionals informed, educated, and entertained.

Website | Podcast

Imran Sadiq

Imran has 17+ years of web design and marketing experience. His YouTube channel has over 55k YouTube subscribers.

Website | YouTube

Rich Tabor

Rich describes himself as a multidisciplinary maker specializing in the intersection of product, design, and engineering.

Website | X (Twitter)

Jamie Marsland

Jamie has trained over 5,000 people on WordPress in the past 10 years, and he also makes WordPress plugins. His YouTube channel is dedicated to helping people with WordPress Blocks.

Website | YouTube

Scroll to Top