Wholesome Code Wholesome Code
Wholesome Code Wholesome Code
  • Blog
  • Guides
  • Plugins
  • About
  • Contact

Matt Watson

Wholesome Code > Articles by: Matt Watson
C.

Create a Custom Sidebar with PluginSidebar

March 30, 2021 3:06 pmMarch 30, 2021By Matt WatsonIn Guides, WordPress0 Comments107 Views
{ __( 'Display Settings', 'wholesome-plugin' ) } ...

We have taken a look at custom block sidebars, third party block sidebars via InspectorControls, and how to add controls to the post sidebar. In this guide we are going to look at putting our controls in their very own…

Read more

A.

Add Controls to the Post Sidebar with PluginDocumentSettingPanel

March 27, 2021 9:54 pmMarch 30, 2021By Matt WatsonIn Guides, WordPress0 Comments88 Views
import { registerPlugin } from '@wordpress/plugins'; import render from './components/Sidebar'; registerPlugin( 'wholesomecode-wholesome-plugin-sidebar', { icon: 'visibility', render, } );

So far we have taken a look at the block sidebar by adding InspectorControls to our custom blocks and adding controls to core and third party block sidebar with filters and Higher Order Components. In this guide we are going…

Read more

A.

Add Controls to the Core and Third Party Block Sidebar with Filters and Higher Order Components

March 26, 2021 10:55 amMarch 27, 2021By Matt WatsonIn Guides, WordPress0 Comments106 Views
addFilter( 'editor.BlockEdit', 'wholesome-plugin/block-draft-inspector', withInspectorControls, );

In our last guide we looked at adding InspectorControls to our custom blocks to enable us to use controls in the block sidebar. In this guide we are going to build on that, and add a toggle control to the…

Read more

A.

Add a Sidebar to your Custom WordPress Block with InspectorControls

March 25, 2021 9:04 pmMarch 30, 2021By Matt WatsonIn Guides, WordPress0 Comments132 Views

There are several ways to use the block editor (Gutenberg) sidebar in WordPress. You can add controls for just the block, for other blocks, for the entire post, or a create a completely custom sidebar. In this guide we are…

Read more

C.

Create a Custom Block Category in the WordPress Block Inserter (Gutenberg)

March 19, 2021 12:22 pmMarch 19, 2021By Matt WatsonIn Blog, WordPress0 Comments90 Views

Are you writing a lot of WordPress block editor (Gutenberg) blocks for just one client? Wouldnt it be good to just group them all together? Simple, just create a custom block category. In the PHP of your plugin just add…

Read more

A.

Add a Custom Settings Link to Your WordPress Plugin

March 19, 2021 11:41 amMarch 19, 2021By Matt WatsonIn Blog, WordPress0 Comments109 Views
function wholesomecode_wholesome_plugin_settings_link( $links ) : array { $label = esc_html__( 'Settings', 'wholesome-plugin' ); $slug = 'wholesome_plugin_settings'; array_unshift( $links,

Have you ever noticed how some plugins have one or more custom links on the WordPress Plugin screen? To be honest if I cannot find the settings for the plugin this is the first place I look: If you want…

Read more

E.

Extend the WordPress Customizer Using JavaScript

March 18, 2021 9:52 pmMarch 18, 2021By Matt WatsonIn Blog, WordPress0 Comments73 Views
customize.control.add( new customize.Control( 'wholesomecode-wholesome-plugin-customizer-gutenberg-control', { description: __( 'Example Description', 'wholesome-plugin' ), label: __( 'Example Text', 'wholesome-plugin' ), section: sectionKey, setting: 'wholesomecode_wholesome_plugin_example_text', type: 'text', }) );

Did you know that you can create Customizer Sections and Panels in JavaScript? Did you know that you can also register Customizer Settings and Controls in JavaScript too? You can do all that and more, with code similar to the…

Read more

H.

Hook into the Save Action for the WordPress Block Editor (Gutenberg)

March 18, 2021 9:21 pmMarch 20, 2021By Matt WatsonIn Blog, WordPress0 Comments98 Views

Have you ever wondered how you can perform an action on save when using Gutenberg? Are you looking for a hook or a filter so you can perform an action when saving a post? Good news, you can easily hook…

Read more

C.

Create a Customizer Panel using WordPress Block Editor (Gutenberg) Components

March 17, 2021 8:43 pmApril 11, 2021By Matt WatsonIn Guides, WordPress4 Comments388 Views

In our last guide we looked at creating a settings page using WordPress Block Editor (Gutenberg) components. In this guide we are going to take it even further and use Gutenberg components inside the WordPress Customizer. Create two new files…

Read more

C.

Create a Settings Page using WordPress Block Editor (Gutenberg) Components

March 14, 2021 8:52 pmMarch 19, 2021By Matt WatsonIn Guides, WordPress0 Comments388 Views

We have previously looked at storing options and settings using the WordPress Block Editor (Gutenberg), and expanding the Create Block Script to allow for extra end points. In this guide we are going to put them all together to create…

Read more

Posts navigation

1 2 3 4 5 6 7 8 Next

Useful Links

  • About
  • Terms and Conditions
  • Privacy Policy
  • Cookie Policy
  • Contact

Guides

  • Create a Custom Sidebar with PluginSidebar
  • Add Controls to the Post Sidebar with PluginDocumentSettingPanel
  • Add Controls to the Core and Third Party Block Sidebar with Filters and Higher Order Components

Latest Posts

  • Create a Custom Block Category in the WordPress Block Inserter (Gutenberg)
  • Add a Custom Settings Link to Your WordPress Plugin
  • Extend the WordPress Customizer Using JavaScript
  • Hook into the Save Action for the WordPress Block Editor (Gutenberg)

About

Wholesome Code: Crafting wonderfully wholesome things with WordPress.

Subscribe

© 2019 – 2021 Wholesome Code Ltd.
All rights reserved | Business No: 12196107

Menu
  • Blog
  • Guides
  • Plugins
  • About
  • Contact
Search