query-editor

Create and modify Miroir Queries using a Test-Driven Development workflow.

2|1|Updated Mar 24, 2024
One-click install
npx skills add https://github.com/miroir-framework/miroir --skill query-editor
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: query-editor
Source: https://github.com/miroir-framework/miroir/tree/main/.github/skills/query-editor
Command: npx skills add https://github.com/miroir-framework/miroir --skill query-editor

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill guides you in creating and updating Miroir Queries using a Test-Driven Development approach, helping you define behavior before implementation.

Core Features & Use Cases

  • TDD workflow: Write tests first for transformer definitions and query behavior, then implement the handler and wire it into runtime.
  • Comprehensive coverage: Supports both library-implemented and composite transformers, with clear guidance for unit and integration tests.
  • Rapid iteration: Provides a repeatable path to create, modify, and validate queries in the Miroir core.

Quick Start

Pre-flight tests, write tests for the transformer definition, implement the handleTransformer_<name> function, register it in the runtime, and run build and integration tests to validate changes.

Frequently Asked Questions about query-editor

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

FAQPage Schema
How do I create Miroir Queries using a Test-Driven Development approach?

To create Miroir Queries with TDD, you write tests for transformer definitions first, then implement the handleTransformer_<name> function, and finally register the transformer in core exports for runtime execution and build-time type generation.

What is the process for wiring a composite transformer into the Miroir runtime?

Wiring a composite transformer into the Miroir runtime involves updating TransformerDefinition JSONs, implementing the handler function, and registering it in core exports to ensure proper build-time type generation and runtime execution across unit and integration phases.

How does TDD apply to library-implemented transformers in Miroir?

TDD for library-implemented transformers in Miroir requires writing pre-flight tests, defining the expected behavior in tests before implementation, and then validating the transformer handler through both unit and integration tests.

Do I need to update TransformerDefinition JSONs when modifying a Miroir Query?

Yes, updating TransformerDefinition JSONs is required when modifying a Miroir Query to define the behavior before implementing the handler and wiring it into the build process for type generation.

What is the best way to validate changes to Miroir Query transformers?

The best way to validate changes to Miroir Query transformers is to run both build and integration tests after registering the transformer in the runtime, ensuring the handler works correctly across all phases.

Why should I use TDD precision when crafting Miroir Queries?

Using TDD precision when crafting Miroir Queries helps you define behavior before implementation, providing a repeatable path to create, modify, and validate queries with clear guidance for both library-implemented and composite transformers.