{"id":73258,"date":"2025-02-04T18:00:29","date_gmt":"2025-02-04T10:00:29","guid":{"rendered":"https:\/\/www.hongkiat.com\/blog\/?p=73258"},"modified":"2025-01-31T19:26:52","modified_gmt":"2025-01-31T11:26:52","slug":"howdy-modern-wordpress-plugin-boilerplate-guide","status":"publish","type":"post","link":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/","title":{"rendered":"Howdy: Modern WordPress Plugin Boilerplate"},"content":{"rendered":"<p>WordPress is a <a href=\"https:\/\/www.hongkiat.com\/blog\/desktop-blogging-clients-the-ultimate-list\/\">popular blogging platform<\/a> built with PHP, and its extensibility is one of its greatest strengths. While you can create a plugin by dropping a single PHP file into your <code>wp-content\/plugins<\/code> directory, the broader development practices for WordPress plugins haven\u2019t evolved much over the years-even as PHP itself has improved significantly.<\/p>\n<p>PHP has changed significantly with new features and syntax. For example, it now includes better and proper OOP features and autoloading. However, WordPress still promotes the old procedural programming approach, and it\u2019s not straightforward to include autoloading in your plugin.<\/p>\n<p>This is why I created <strong><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/github.com\/syntatis\/howdy\">Howdy<\/a><\/strong>, a WordPress plugin boilerplate that aims to make using modern PHP concepts in WordPress plugin development easier.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/cover.jpg\" alt=\"Howdy WordPress Plugin Boilerplate Cover Image\" width=\"1000\" height=\"640\"><\/figure>\n<h2>Scope<\/h2>\n<p>Howdy <strong>focuses on essential tools<\/strong> that improve productivity without overcomplicating the workflow. Rather than forcing every modern PHP practice into it, it prioritizes two foundational features:<\/p>\n<ul>\n<li><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/www.php.net\/manual\/en\/language.namespaces.php\">Namespacing<\/a><\/li>\n<li><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/www.php.net\/manual\/en\/language.oop5.autoload.php\">Autoloading<\/a> (with <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/getcomposer.org\">Composer<\/a>)<\/li>\n<\/ul>\n<h3>Namespacing<\/h3>\n<p>Namespacing in PHP organizes classes, functions, and constants into logical groups, similar to how folders structure files, to prevent naming collisions. For example, two plugins defining a <code>Security<\/code> class won\u2019t conflict if each uses a unique namespace.<\/p>\n<p>Traditionally, WordPress relies on prefixes for isolation. Suppose your plugin is named \u201cSimple Security by Acme.\u201d You\u2019d typically prefix functions and classes with your organization name <code>Acme_<\/code> or <code>acme_<\/code>:<\/p>\n<pre>\r\n\/\/ Prefix in a function name.\r\nfunction acme_check_security() {\r\n    \/\/ Add security check logic here\r\n}\r\n\r\n\/\/ Prefix in a class name.\r\nclass Acme_Security {\r\n    public function check() {\r\n        \/\/ Add class-specific logic here\r\n    }\r\n}\r\n<\/pre>\n<p>While namespaces can be used in WordPress plugins, adoption remains rare. This is because you can\u2019t use namespaces to their full potential without autoloading.<\/p>\n<h3>Autoloading<\/h3>\n<p>Autoloading classes in WordPress has two key limitations.<\/p>\n<p>First, you can\u2019t autoload third-party libraries, like <strong><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/github.com\/openai-php\/client\">openai-php\/client<\/a><\/strong>, without prefixing their namespaces. If two plugins load the same library, conflicting definitions will crash the site.<\/p>\n<p>Additionally, without using Composer, all functions, constants, or static files must be manually loaded with <code>require_once<\/code>, increasing boilerplate.<\/p>\n<p>These are the two main issues that <strong>Howdy<\/strong> aims to tackle.<\/p>\n<p>Once we have these two features properly set up, adopting other advanced PHP patterns, such as <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/php-di.org\/doc\/understanding-di.html\">dependency injection<\/a> or <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/refactoring.guru\/design-patterns\/facade\/php\/example\">facades<\/a>, becomes much easier.<\/p>\n<p><strong>So let\u2019s install Howdy<\/strong> and see it in action.<\/p>\n<h2>Installation<\/h2>\n<p>We can install Howdy with the Composer <code>create-project<\/code> command:<\/p>\n<pre>\r\ncomposer create-project syntatis\/howdy -s dev\r\n<\/pre>\n<p>This command will create a new directory, <code>howdy<\/code>, pull all the project files, and install the dependencies from <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/packagist.org\">Packagist<\/a>.<\/p>\n<p>If you want to create the project in a different folder, you can add the directory name at the end of the command, like below:<\/p>\n<pre>\r\ncomposer create-project syntatis\/howdy -s dev acme-plugin\r\n<\/pre>\n<p>It will then ask you to input the plugin slug. The plugin slug is required and should be unique. If you plan to publish your plugin on WordPress.org, this slug will be used in the plugin URL, e.g., <code>https:\/\/wordpress.org\/plugins\/{slug}\/<\/code>. For this example, we\u2019ll use <code>acme-plugin<\/code>.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/prompt-plugin-slug.jpg\" alt=\"Prompt to Input Plugin Slug in Howdy\" width=\"1000\" height=\"500\"><\/figure>\n<p>The plugin slug will also be used to determine the default plugin name, the namespace prefix, and more. As we can see below, it\u2019s smart enough to transform the slug into the appropriate format. For this example, we\u2019ll keep the default plugin name while changing the namespace to <code>Acme<\/code> instead of <code>AcmePlugin<\/code>.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/prompt-plugin-name-namespace.jpg\" alt=\"Prompt to Input Plugin Name and Namespace in Howdy\" width=\"1000\" height=\"500\"><\/figure>\n<p>Once the inputs are completed, the necessary updates are made to the project files. For example, the file in <code>app\/Plugin.php<\/code> will include the namespace and the prefix for the dependencies\u2019 namespace.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/prompt-file-namespace.jpg\" alt=\"Plugin Namespace and Prefix in Howdy Example\" width=\"1000\" height=\"500\"><\/figure>\n<h2>What\u2019s Included?<\/h2>\n<p>Howdy comes pre-configured with these tools to streamline development:<\/p>\n<ul>\n<li><strong><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/github.com\/humbug\/php-scoper\">PHP-Scoper<\/a><\/strong>: It allows us to add prefixes for dependencies installed with Composer to prevent conflicts when using the same libraries.<\/li>\n<li><strong><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/github.com\/PHPCSStandards\/PHP_CodeSniffer\/\">PHPCS<\/a><\/strong>: It includes PHPCS, but instead of using the <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/github.com\/WordPress\/WordPress-Coding-Standards\">WordPress Coding Standard<\/a>, the library applies modern coding standards that are well-established in the PHP ecosystem, such as <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/www.php-fig.org\/psr\/psr-12\/\">PSR-12<\/a>, <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/github.com\/doctrine\/coding-standard\">Doctrine<\/a>, and <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/github.com\/slevomat\/coding-standard\">Slevomat<\/a>.<\/li>\n<li><strong><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/kubrick.syntatis.com\/\">Kubrick<\/a><\/strong>: A collection of React.js components to build applications like the settings page in the WordPress admin.<\/li>\n<li><strong><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/www.npmjs.com\/package\/@wordpress\/scripts\">@wordpress\/scripts<\/a><\/strong>: To compile JavaScript and stylesheets. You can run the following command to start watching files and automatically compile changes:\n<pre>\r\nnpm run start\r\n<\/pre>\n<\/li>\n<\/ul>\n<h2>Directory Structure<\/h2>\n<p><strong>Howdy<\/strong> uses a slightly unconventional structure for a WordPress plugin. However, if you\u2019re familiar with frameworks like <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/laravel.com\">Laravel<\/a> or <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/symfony.com\">Symfony<\/a>, you\u2019ll adapt quickly.<\/p>\n<p>There are three main directories:<\/p>\n<ol>\n<li><strong>app<\/strong>: This directory should house your plugin\u2019s core classes and business logic. Classes in this directory are autoloaded automatically if they follow the <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/www.php-fig.org\/psr\/psr-4\/\">PSR-4 standard<\/a>.<\/li>\n<li><strong>inc<\/strong>: This directory contains configuration files, utilities, and HTML templates.<\/li>\n<li><strong>src<\/strong>: This directory contains the uncompiled source for JavaScript and stylesheet files.<\/li>\n<\/ol>\n<h2>Installing External Dependencies<\/h2>\n<p>Now that we have the plugin boilerplate set up, we can easily install additional packages with Composer. For example, if we want to build a plugin with OpenAI integration, we can include the <code>openai-php\/client<\/code> package using the following command:<\/p>\n<pre>\r\ncomposer require openai-php\/client\r\n<\/pre>\n<p>Howdy will automatically add a prefix to the namespaces of all classes in this package after it\u2019s installed.<\/p>\n<p>You can also install packages specifically for development. For example, to install <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/github.com\/symfony\/var-dumper\"><strong>symfony\/var-dumper<\/strong><\/a>, a popular PHP package for debugging, you can run:<\/p>\n<pre>\r\ncomposer require symfony\/var-dumper --dev\r\n<\/pre>\n<p>This package provides a more user-friendly debugging experience compared to PHP\u2019s native <code>var_dump<\/code> function.<\/p>\n<figure><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/dd-use.jpg\" alt=\"Example of Symfony Var Dumper Usage\" width=\"1000\" height=\"500\"><\/figure>\n<h2>Preparing for Production<\/h2>\n<p>Lastly, Howdy provides several commands to prepare your plugin for release:<\/p>\n<p><code>npm run build<\/code>: Builds all asset files, including JavaScript and stylesheets, in the <code>src<\/code> directory. These files are optimized and minified for production.<\/p>\n<p><code>composer run build<\/code>: Re-compiles the project and removes packages installed for development.<\/p>\n<p><code>composer run plugin:zip<\/code>: Creates an installable ZIP file for the plugin. Unnecessary files like dotfiles, <code>src<\/code> directories, and <code>node_modules<\/code> are excluded from the final archive.<\/p>\n<h2>Wrapping Up<\/h2>\n<p>In this article, we\u2019ve explored Howdy and its benefits for WordPress plugin development.<\/p>\n<p>Howdy is designed to modernize plugin development without overwhelming you. It avoids bloating your workflow with every trendy tool (e.g., PHPUnit, PHPStan, or TypeScript are not included by default), but you can add them later as needed.<\/p>\n<p>By solving dependency conflicts and enabling Composer, Howdy bridges WordPress development with the broader PHP ecosystem, unlocking countless possibilities for building maintainable and scalable plugins.<\/p>","protected":false},"excerpt":{"rendered":"<p>WordPress is a popular blogging platform built with PHP, and its extensibility is one of its greatest strengths. While you can create a plugin by dropping a single PHP file into your wp-content\/plugins directory, the broader development practices for WordPress plugins haven\u2019t evolved much over the years-even as PHP itself has improved significantly. PHP has&hellip;<\/p>\n","protected":false},"author":113,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[49],"tags":[3323],"topic":[],"class_list":["entry-content","is-maxi"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v22.8 (Yoast SEO v27.5) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Howdy: Modern WordPress Plugin Boilerplate - Hongkiat<\/title>\n<meta name=\"description\" content=\"WordPress is a popular blogging platform built with PHP, and its extensibility is one of its greatest strengths. While you can create a plugin by dropping\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Howdy: Modern WordPress Plugin Boilerplate\" \/>\n<meta property=\"og:description\" content=\"WordPress is a popular blogging platform built with PHP, and its extensibility is one of its greatest strengths. While you can create a plugin by dropping\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/\" \/>\n<meta property=\"og:site_name\" content=\"Hongkiat\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/hongkiatcom\" \/>\n<meta property=\"article:published_time\" content=\"2025-02-04T10:00:29+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/cover.jpg\" \/>\n<meta name=\"author\" content=\"Thoriq Firdaus\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@tfirdaus\" \/>\n<meta name=\"twitter:site\" content=\"@hongkiat\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Thoriq Firdaus\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/\"},\"author\":{\"name\":\"Thoriq Firdaus\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#\\\/schema\\\/person\\\/e7948c7a175d211496331e4b6ce55807\"},\"headline\":\"Howdy: Modern WordPress Plugin Boilerplate\",\"datePublished\":\"2025-02-04T10:00:29+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/\"},\"wordCount\":941,\"publisher\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/assets.hongkiat.com\\\/uploads\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/cover.jpg\",\"keywords\":[\"WordPress Plugins\"],\"articleSection\":[\"WordPress\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/\",\"name\":\"Howdy: Modern WordPress Plugin Boilerplate - Hongkiat\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/assets.hongkiat.com\\\/uploads\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/cover.jpg\",\"datePublished\":\"2025-02-04T10:00:29+00:00\",\"description\":\"WordPress is a popular blogging platform built with PHP, and its extensibility is one of its greatest strengths. While you can create a plugin by dropping\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/#primaryimage\",\"url\":\"https:\\\/\\\/assets.hongkiat.com\\\/uploads\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/cover.jpg\",\"contentUrl\":\"https:\\\/\\\/assets.hongkiat.com\\\/uploads\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/cover.jpg\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/howdy-modern-wordpress-plugin-boilerplate-guide\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Howdy: Modern WordPress Plugin Boilerplate\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/\",\"name\":\"Hongkiat\",\"description\":\"Tech and Design Tips\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#organization\",\"name\":\"Hongkiat.com\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/wp-content\\\/uploads\\\/hkdc-logo-rect-yoast.jpg\",\"contentUrl\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/wp-content\\\/uploads\\\/hkdc-logo-rect-yoast.jpg\",\"width\":1200,\"height\":799,\"caption\":\"Hongkiat.com\"},\"image\":{\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/hongkiatcom\",\"https:\\\/\\\/x.com\\\/hongkiat\",\"https:\\\/\\\/www.pinterest.com\\\/hongkiat\\\/\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/#\\\/schema\\\/person\\\/e7948c7a175d211496331e4b6ce55807\",\"name\":\"Thoriq Firdaus\",\"description\":\"Thoriq is a writer for Hongkiat.com with a passion for web design and development. He is the author of Responsive Web Design by Examples, where he covered his best approaches in developing responsive websites quickly with a framework.\",\"sameAs\":[\"https:\\\/\\\/thoriq.com\",\"https:\\\/\\\/x.com\\\/tfirdaus\"],\"jobTitle\":\"Web Developer\",\"url\":\"https:\\\/\\\/www.hongkiat.com\\\/blog\\\/author\\\/thoriq\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Howdy: Modern WordPress Plugin Boilerplate - Hongkiat","description":"WordPress is a popular blogging platform built with PHP, and its extensibility is one of its greatest strengths. While you can create a plugin by dropping","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/","og_locale":"en_US","og_type":"article","og_title":"Howdy: Modern WordPress Plugin Boilerplate","og_description":"WordPress is a popular blogging platform built with PHP, and its extensibility is one of its greatest strengths. While you can create a plugin by dropping","og_url":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/","og_site_name":"Hongkiat","article_publisher":"https:\/\/www.facebook.com\/hongkiatcom","article_published_time":"2025-02-04T10:00:29+00:00","og_image":[{"url":"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/cover.jpg","type":"","width":"","height":""}],"author":"Thoriq Firdaus","twitter_card":"summary_large_image","twitter_creator":"@tfirdaus","twitter_site":"@hongkiat","twitter_misc":{"Written by":"Thoriq Firdaus","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/#article","isPartOf":{"@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/"},"author":{"name":"Thoriq Firdaus","@id":"https:\/\/www.hongkiat.com\/blog\/#\/schema\/person\/e7948c7a175d211496331e4b6ce55807"},"headline":"Howdy: Modern WordPress Plugin Boilerplate","datePublished":"2025-02-04T10:00:29+00:00","mainEntityOfPage":{"@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/"},"wordCount":941,"publisher":{"@id":"https:\/\/www.hongkiat.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/#primaryimage"},"thumbnailUrl":"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/cover.jpg","keywords":["WordPress Plugins"],"articleSection":["WordPress"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/","url":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/","name":"Howdy: Modern WordPress Plugin Boilerplate - Hongkiat","isPartOf":{"@id":"https:\/\/www.hongkiat.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/#primaryimage"},"image":{"@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/#primaryimage"},"thumbnailUrl":"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/cover.jpg","datePublished":"2025-02-04T10:00:29+00:00","description":"WordPress is a popular blogging platform built with PHP, and its extensibility is one of its greatest strengths. While you can create a plugin by dropping","breadcrumb":{"@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/#primaryimage","url":"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/cover.jpg","contentUrl":"https:\/\/assets.hongkiat.com\/uploads\/howdy-modern-wordpress-plugin-boilerplate-guide\/cover.jpg"},{"@type":"BreadcrumbList","@id":"https:\/\/www.hongkiat.com\/blog\/howdy-modern-wordpress-plugin-boilerplate-guide\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.hongkiat.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Howdy: Modern WordPress Plugin Boilerplate"}]},{"@type":"WebSite","@id":"https:\/\/www.hongkiat.com\/blog\/#website","url":"https:\/\/www.hongkiat.com\/blog\/","name":"Hongkiat","description":"Tech and Design Tips","publisher":{"@id":"https:\/\/www.hongkiat.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.hongkiat.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.hongkiat.com\/blog\/#organization","name":"Hongkiat.com","url":"https:\/\/www.hongkiat.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.hongkiat.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.hongkiat.com\/blog\/wp-content\/uploads\/hkdc-logo-rect-yoast.jpg","contentUrl":"https:\/\/www.hongkiat.com\/blog\/wp-content\/uploads\/hkdc-logo-rect-yoast.jpg","width":1200,"height":799,"caption":"Hongkiat.com"},"image":{"@id":"https:\/\/www.hongkiat.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/hongkiatcom","https:\/\/x.com\/hongkiat","https:\/\/www.pinterest.com\/hongkiat\/"]},{"@type":"Person","@id":"https:\/\/www.hongkiat.com\/blog\/#\/schema\/person\/e7948c7a175d211496331e4b6ce55807","name":"Thoriq Firdaus","description":"Thoriq is a writer for Hongkiat.com with a passion for web design and development. He is the author of Responsive Web Design by Examples, where he covered his best approaches in developing responsive websites quickly with a framework.","sameAs":["https:\/\/thoriq.com","https:\/\/x.com\/tfirdaus"],"jobTitle":"Web Developer","url":"https:\/\/www.hongkiat.com\/blog\/author\/thoriq\/"}]}},"jetpack_featured_media_url":"https:\/\/","jetpack_shortlink":"https:\/\/wp.me\/p4uxU-j3A","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/posts\/73258","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/users\/113"}],"replies":[{"embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/comments?post=73258"}],"version-history":[{"count":2,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/posts\/73258\/revisions"}],"predecessor-version":[{"id":73260,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/posts\/73258\/revisions\/73260"}],"wp:attachment":[{"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/media?parent=73258"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/categories?post=73258"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/tags?post=73258"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.hongkiat.com\/blog\/wp-json\/wp\/v2\/topic?post=73258"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}