Plugin development and composer

So, I want to find some solution where I can set only the composer.json file inside the plugin folder and after the plugin activation to pull and install the required SDK. That’s not how it works. Composer is a CLI tool that’s meant to be ran via CLI, and wasn’t designed to run in a … Read more

How to display the category id along with category name on categories list?

You can add new column using below code. replace (your-texanomy) with your taxonomy slug. I have tested and its working fine. https://prnt.sc/qbibg0 #add header before category name function taxonomy_custom_column_header( $columns ){ $columns = array_slice($columns, 0, 1, true) + array(“cat_id” => “ID”) + array_slice($columns, 1, count($columns) – 1, true) ; return $columns; } add_filter( “manage_edit-(your-texanomy)_columns”, ‘taxonomy_custom_column_header’, … Read more

Converting data-name editor plugin to Gutenberg plugin

Looking at the Gutenberg code in the GitHub repo, we can look at how the inline image format is implemented: https://github.com/WordPress/gutenberg/blob/99f31cdb4ed035264e0332b72dd3a2287d93ff50/packages/format-library/src/image/index.js#L17-L30 export const image = { name, title: __( ‘Image’ ), keywords: [ __( ‘photo’ ), __( ‘media’ ) ], object: true, tagName: ‘img’, className: null, attributes: { className: ‘class’, style: ‘style’, url: ‘src’, alt: … Read more

Can we use a library under MIT license in a WooCommerce plugin?

Disclaimer: I’m not a lawyer, so this isn’t legal advice. Yes, you can include MIT licensed code in something you sell. The MIT license is very permissive. From the license: Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in … Read more