{"id":196387,"date":"2024-08-04T13:28:00","date_gmt":"2024-08-04T13:28:00","guid":{"rendered":"https:\/\/wordpress.org\/plugins\/youbou-code-block\/"},"modified":"2026-10-11T15:29:43","modified_gmt":"2026-10-11T15:29:43","slug":"youbou-code-block","status":"publish","type":"plugin","link":"https:\/\/mk.wordpress.org\/plugins\/youbou-code-block\/","author":21129572,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"1.0.1","stable_tag":"1.0.1","tested":"7.1.4","requires":"6.1","requires_php":"7.2","requires_plugins":null,"header_name":"Youbou Code Block","header_author":"Youssef Bouhlal","header_description":"Code block with syntax highlighting for gutenberg editor.","assets_banners_color":"","last_updated":"2026-10-11 15:29:43","external_support_url":"","external_repository_url":"","donate_link":"","header_plugin_uri":"https:\/\/github.com\/YoussefBouhlal\/youbou-code-block","header_author_uri":"https:\/\/github.com\/YoussefBouhlal","rating":0,"author_block_rating":0,"active_installs":0,"downloads":1746,"num_ratings":0,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"1.0":{"tag":"1.0","author":"youssefbouhlal","date":"2024-08-04 13:27:32","revision":3130637},"1.0.1":{"tag":"1.0.1","author":"youssefbouhlal","date":"2026-10-11 15:29:43","revision":3739688}},"upgrade_notice":{"1.0.1":"<p>Includes a Prism security fix and code-preservation improvements. Previously altered code cannot be reconstructed automatically; review it against your original source if needed.<\/p>","1.0":"<ul>\n<li>Initial release of the plugin. No upgrades are required.<\/li>\n<\/ul>"},"ratings":[],"assets_icons":[],"assets_banners":[],"assets_blueprints":{},"all_blocks":{"youbou\/code-block":{"$schema":"https:\/\/schemas.wp.org\/trunk\/block.json","apiVersion":3,"name":"youbou\/code-block","version":"1.0.1","title":"Youbou Code Block","category":"text","icon":"smiley","description":"Code block with syntax highlighting.","supports":{"html":false,"className":false},"attributes":{"code":{"type":"string","default":"","source":"text","selector":"code"},"langType":{"type":"string","default":""},"langName":{"type":"string","default":""}},"textdomain":"youbou-code-block","editorScript":"file:.\/index.js","editorStyle":"file:.\/index.css","style":"file:.\/style-index.css","viewScript":"file:.\/view.js"}},"tagged_versions":["1.0","1.0.1"],"block_files":[],"assets_screenshots":{"screenshot-1.png":{"filename":"screenshot-1.png","revision":3130637,"resolution":"1","location":"assets","locale":"","width":1000,"height":601},"screenshot-2.png":{"filename":"screenshot-2.png","revision":3130637,"resolution":"2","location":"assets","locale":"","width":1000,"height":601}},"screenshots":[]},"plugin_section":[],"plugin_tags":[12156,20421,151844,230313,4609],"plugin_category":[],"plugin_contributors":[230314],"plugin_business_model":[],"class_list":["post-196387","plugin","type-plugin","status-publish","hentry","plugin_tags-code-highlighting","plugin_tags-copy-to-clipboard","plugin_tags-gutenberg-block","plugin_tags-programming-languages","plugin_tags-syntax-highlighting","plugin_contributors-youssefbouhlal","plugin_committers-youssefbouhlal"],"banners":[],"icons":{"svg":false,"icon":"https:\/\/s.w.org\/plugins\/geopattern-icon\/youbou-code-block.svg","icon_2x":false,"generated":true},"screenshots":[{"src":"https:\/\/ps.w.org\/youbou-code-block\/assets\/screenshot-1.png?rev=3130637","caption":""},{"src":"https:\/\/ps.w.org\/youbou-code-block\/assets\/screenshot-2.png?rev=3130637","caption":""}],"raw_content":"<!--section=description-->\n<p>The Youbou Code Block is a Gutenberg block plugin for WordPress that allows users to easily add syntax-highlighted code snippets to their posts and pages. This plugin supports a wide range of programming languages and includes a convenient copy-to-clipboard functionality.<\/p>\n\n<h3>Features<\/h3>\n\n<ul>\n<li>Syntax highlighting for various programming languages<\/li>\n<li>Supports the following languages:\n\n<ul>\n<li>HTML<\/li>\n<li>CSS<\/li>\n<li>SCSS<\/li>\n<li>JavaScript<\/li>\n<li>TypeScript<\/li>\n<li>PHP<\/li>\n<li>Ruby<\/li>\n<li>Python<\/li>\n<li>Swift<\/li>\n<li>C<\/li>\n<li>C#<\/li>\n<li>C++<\/li>\n<li>Objective-C<\/li>\n<li>SQL<\/li>\n<li>JSON<\/li>\n<li>Bash<\/li>\n<li>Git<\/li>\n<\/ul><\/li>\n<li>Copy-to-clipboard functionality for code snippets<\/li>\n<li>Easy to use Gutenberg block interface<\/li>\n<\/ul>\n\n<h3>Development<\/h3>\n\n<p>Use the Node version in <code>.nvmrc<\/code>, then run <code>npm ci<\/code>, <code>composer install<\/code>, <code>npm test<\/code>, and <code>npm run build<\/code>.\nRun <code>npm run test:browser<\/code> after installing Chromium with <code>npx playwright install chromium<\/code>.\nRun the configured lint commands and Plugin Check before publishing. <code>npm run release<\/code> builds a production ZIP with its Composer autoloader in <code>release\/<\/code>; it does not deploy the plugin.\nRegenerate messages with <code>npm run i18n:pot<\/code>. When translated PO files are available, use <code>npm run i18n:json<\/code> to produce catalogs mapped to the shipped bundles. No translations are fabricated by these commands.<\/p>\n\n<h3>License<\/h3>\n\n<p>This plugin is licensed under the GPLv2 or later. For more information, see <a href=\"http:\/\/www.gnu.org\/licenses\/gpl-2.0.html\">http:\/\/www.gnu.org\/licenses\/gpl-2.0.html<\/a>.<\/p>\n\n<!--section=installation-->\n<ol>\n<li>Upload the complete release ZIP through the WordPress plugins screen, or extract it into <code>\/wp-content\/plugins\/youbou-code-block<\/code>.<\/li>\n<li>Activate the plugin through the 'Plugins' screen in WordPress.<\/li>\n<li>Navigate to the Gutenberg editor and add the 'Youbou Code Block' to your post or page.<\/li>\n<li>Select the programming language and add your code.<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt id=\"what%20programming%20languages%20are%20supported%3F\"><h3>What programming languages are supported?<\/h3><\/dt>\n<dd><p>The plugin supports the following languages:\n* HTML\n* CSS\n* SCSS\n* JavaScript\n* TypeScript\n* PHP\n* Ruby\n* Python\n* Swift\n* C\n* C#\n* C++\n* Objective-C\n* SQL\n* JSON\n* Bash\n* Git<\/p><\/dd>\n<dt id=\"how%20do%20i%20use%20the%20copy-to-clipboard%20functionality%3F\"><h3>How do I use the copy-to-clipboard functionality?<\/h3><\/dt>\n<dd><p>Use the 'Copy code' button above the code block. It is available with a keyboard or touch. If clipboard access fails, select the code and press Ctrl+C or Command+C.<\/p><\/dd>\n<dt id=\"will%20updating%20repair%20code%20previously%20changed%20by%20html%20entity%20decoding%3F\"><h3>Will updating repair code previously changed by HTML entity decoding?<\/h3><\/dt>\n<dd><p>Version 1.0.1 preserves literal entities in newly saved code. It preserves the text parsed from existing blocks, but cannot infer the original spelling of code already changed by earlier versions. Restore that text from a revision or your original source if necessary.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>1.0.1<\/h4>\n\n<ul>\n<li>Preserve literal HTML entities when saving and reopening code.<\/li>\n<li>Update Prism to 1.30.0 and isolate highlighting and styles to this block.<\/li>\n<li>Improve keyboard focus, editor labels, translated copy feedback, and clipboard fallback handling.<\/li>\n<li>Correct minimum-version checks, translation paths, and release packaging.<\/li>\n<\/ul>\n\n<h4>1.0<\/h4>\n\n<ul>\n<li>Initial release of the Code Highlighting Block plugin.<\/li>\n<\/ul>","raw_excerpt":"Code block with syntax highlighting for gutenberg editor.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/196387","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=196387"}],"author":[{"embeddable":true,"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/youssefbouhlal"}],"wp:attachment":[{"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=196387"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=196387"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=196387"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=196387"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=196387"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/mk.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=196387"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}