johnnystefan/test-saas-business/pattern-proxy

Claude Code and agent skill by johnnystefan/test-saas-business

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Teaches and applies the Proxy structural design pattern — providing a substitute for another object to control access, add lazy loading, logging, or caching. Trigger: When controlling access to objects, adding cross-cutting concerns, or lazy loading.

Install

npx vskill@latest install johnnystefan/test-saas-business/pattern-proxy

SKILL.md

The same SKILL.md was published earlier as johnnystefan/test-saas-business/pattern-proxy.

Skill: Implement Proxy Pattern

Purpose

Provides a substitute or placeholder for another object to control access to it (e.g., lazy loading, logging, access control).

Procedural Instructions

  1. Define Service Interface: Create an interface that both the real service and the proxy will follow.
  2. Create Real Service: The class that performs the actual business logic.
  3. Create Proxy: Implements the same interface, maintains a reference to the service, and controls access/execution.

TypeScript Example

typescript
interface Subject {
request(): void;
}
class RealSubject implements Subject {
request() {
console.log('RealSubject handling request');
}
}
class ProxySubject implements Subject {
private realSubject: RealSubject | null = null;
request() {
if (this.checkAccess()) {
if (!this.realSubject) this.realSubject = new RealSubject(); // Lazy Init
this.realSubject.request();
this.logAccess();
}
}
private checkAccess(): boolean {
return true;
}
private logAccess() {
console.log('Proxy: Logging request');
}
}

Payoff

  • Control: Manage service lifecycle and access without modifying the service class.
  • Robustness: The proxy works even if the service isn't ready or available.

Security

  • Security scanPassed, 90 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationNot runNo evaluation yet. Run one in Skill Studio.

Source

Popularity

7-day trend score
5

Not refreshed yet.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/johnnystefan/test-saas-business/pattern-proxy/badge)](https://verified-skill.com/skills/johnnystefan/test-saas-business/pattern-proxy)

Something wrong with this skill or its page? Tell us.