architecture

Implement Trailblazer 2.1 clean architecture patterns in Rails applications.

Updated Jan 20, 2023
One-click install
npx skills add https://github.com/doncan-orozco/papyro --skill architecture-doncan-orozco
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: architecture
Source: https://github.com/doncan-orozco/papyro/tree/main/.ai/skills/architecture
Command: npx skills add https://github.com/doncan-orozco/papyro --skill architecture-doncan-orozco

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill provides a structured approach to building scalable and maintainable Rails applications by implementing clean architecture principles and leveraging the Trailblazer gem for organized business logic.

Core Features & Use Cases

  • Organized Codebase: Follows a clear file structure for controllers, operations, contracts, models, queries, and services.
  • Testable Logic: Encapsulates business logic in operations and services for easier testing.
  • Use Case: When developing a new feature that involves user authentication, you would use this Skill to structure the operations for user creation, validation, and session management, ensuring a clean separation of concerns.

Quick Start

Use the architecture skill to create a new operation for handling user sign-ups.

Frequently Asked Questions about architecture

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

FAQPage Schema
How do I structure a Rails application using clean architecture patterns?

Rails business logic is organized using Trailblazer 2.1 operations, contracts, queries, and services. This Skill provides file structure conventions and development workflows for clean separation of concerns.

What is the best way to organize Rails controllers and models for scalability?

Organizing Rails controllers and models for scalability involves encapsulating business logic in operations and services. This Skill defines a clear file structure for controllers, operations, contracts, models, and queries.

How do I implement user authentication operations in Rails with Trailblazer?

User authentication in Rails via Trailblazer involves creating operations for user creation, validation, and session management. This Skill guides structuring these operations to ensure clean separation of concerns.

Does Trailblazer 2.1 work well for domain-driven Rails application structure?

Trailblazer 2.1 fully supports domain-driven Rails application structure. This Skill covers domain-driven organization, operations, contracts, and queries for robust application development.

Can I use this architecture approach for testing Rails business logic?

Yes, this architecture approach improves testing Rails business logic by encapsulating it in operations and services. This encapsulation makes your application logic significantly easier to test in isolation.