kotlin-patterns

Enforces idiomatic Kotlin patterns, null safety and structured concurrency in codebases.

1|Updated Apr 6, 2026
One-click install
npx skills add https://github.com/vrcms/everything-qwen-code --skill kotlin-patterns-vrcms
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: kotlin-patterns
Source: https://github.com/vrcms/everything-qwen-code/tree/main/.qwen/skills/kotlin-patterns
Command: npx skills add https://github.com/vrcms/everything-qwen-code --skill kotlin-patterns-vrcms

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill addresses the challenge of writing non-idiomatic or fragile Kotlin code by providing a comprehensive set of best practices for null safety, concurrency, and type-safe DSLs.

Core Features & Use Cases

  • Idiomatic Conventions: Enforces null safety, immutability, and concise expression-based syntax.
  • Advanced Architecture: Provides patterns for sealed hierarchies, structured concurrency with coroutines, and type-safe DSL builders.
  • Use Case: When refactoring a legacy Java-style Kotlin codebase, use this Skill to transition to functional-style collection processing, structured concurrency, and exhaustive type hierarchies.

Quick Start

Apply the kotlin-patterns skill to review the current module and suggest refactoring opportunities for null safety and coroutine usage.

Frequently Asked Questions about kotlin-patterns

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

FAQPage Schema
How do I refactor Java-style Kotlin code to use idiomatic patterns?

Idiomatic Kotlin uses sealed class hierarchies to represent exhaustive type states safely. This approach standardizes backend service development and library design by enforcing exhaustive type hierarchies for robust, maintainable reactive codebases.

What is the best way to implement structured concurrency in Kotlin?

Structured concurrency in Kotlin is implemented using coroutines and Flow. Applying these patterns standardizes asynchronous backend service development, ensuring maintainable, type-safe, and reactive codebases without fragile threading.

How do I build type-safe DSLs in Gradle using Kotlin?

Type-safe DSLs in Gradle use Kotlin's builder patterns and concise syntax. This standardizes build configuration and library design, producing maintainable, type-safe reactive codebases with robust null safety.

Can I use this to enforce null safety in legacy Kotlin codebases?

Yes, enforcing null safety in legacy Kotlin codebases involves applying idiomatic conventions and immutability. This transitions fragile Java-style code to functional-style collection processing and robust, type-safe architectures.

When should I use sealed class hierarchies in Kotlin backend services?

Sealed class hierarchies in Kotlin backend services should be used to represent exhaustive type states safely. This standardizes library design and architecture by enforcing type-safe, maintainable reactive codebases.