wp-guard

Review changed WordPress code for security, translation, and performance issues.

Updated Jun 14, 2026
One-click install
npx skills add https://github.com/basmawebinfo-hub/lover-diet-center --skill wp-guard
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: wp-guard
Source: https://github.com/basmawebinfo-hub/lover-diet-center/tree/main/.opencode/skills/wp-guard
Command: npx skills add https://github.com/basmawebinfo-hub/lover-diet-center --skill wp-guard

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps catch the WordPress-specific mistakes that often slip into generated or edited code before release, especially security flaws, broken internationalization, misuse of core APIs, and performance issues that only appear at scale.

Core Features & Use Cases

  • WordPress security review: Checks for missing escaping, missing sanitization, absent nonce and capability validation, and unsafe SQL involving $wpdb.
  • Platform-correct implementation guidance: Enforces use of WordPress core APIs for hooks, HTTP requests, redirects, assets, filesystem operations, and namespacing or prefixing.
  • Translation and scaling readiness: Reviews user-facing strings for proper i18n wrappers and text domains, and flags query, caching, and asset-loading patterns that hurt production performance.
  • Use cases: Ideal after creating or modifying plugins, themes, blocks, AJAX handlers, REST routes, shortcodes, meta boxes, WP_Query logic, widgets, or WP-CLI commands, and also useful for structured review-only audits.

Quick Start

Use the wp-guard skill to review the changed WordPress plugin files for security, translation readiness, and performance problems before merge.

Frequently Asked Questions about wp-guard

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I review WordPress plugin code for security vulnerabilities before release?

Review WordPress plugin code for security vulnerabilities by checking for missing escaping, unslash-then-sanitize input handling, nonce plus capability enforcement, and prepared database queries before release.

What WordPress-specific code mistakes should I look for during a theme audit?

During a WordPress theme audit, look for core API misuse, broken internationalization wrappers, missing text domains, unsafe SQL involving $wpdb, and asset-loading patterns that hurt production performance.

Can I use this to check translation readiness in WordPress blocks and shortcodes?

Yes, you can check translation readiness in WordPress blocks and shortcodes by reviewing user-facing strings for proper i18n wrappers and verifying that text domains are correctly applied.

What's the best way to enforce WordPress core API usage in custom REST routes?

Enforce WordPress core API usage in custom REST routes by verifying hooks, ensuring prefixed public names, and applying context-correct escaping alongside proper HTTP request and redirect handling.

Why does my WP_Query logic trigger performance risks during code review?

WP_Query logic triggers performance risks during code review when it lacks disciplined query and caching patterns, causing inefficient database lookups and asset-loading bottlenecks at production scale.

Do I need to check nonce and capability validation for WP-CLI commands?

You need to check nonce and capability validation for WP-CLI commands and AJAX handlers to ensure secure authentication, alongside verifying prepared database queries and proper input sanitization.