wp-plugin-presenter
CommunityDesign and review WordPress presenter classes.
AuthorLonsdale201
Version1.0.0
Installs0
System Documentation
What problem does it solve?
Design and review native WordPress presenter classes to map DTOs or domain objects into REST arrays, admin table rows, JS config payloads, email variables, and public view models without mutating the underlying data and with robust escaping and redaction controls.
Core Features & Use Cases
- Provide per-context output methods: for_rest(), for_admin_table(), for_js_config(), for_email(), for_export().
- Enforce allowlisted fields and redact sensitive data by default to reduce leakage.
- Avoid DTO mutation; presenter computes output arrays and escapes at the final boundary.
- Support collection presenters that re-use per-item presenters to prevent duplication.
Quick Start
Create a Presenter class for your DTO and use its for_rest() output in REST endpoints, adding for_admin_table() and for_js_config() as needed.
Dependency Matrix
Required Modules
None requiredComponents
references
💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: wp-plugin-presenter Download link: https://github.com/Lonsdale201/wp-agent-skills/archive/main.zip#wp-plugin-presenter Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.