swe-programming-fsharplisted
Install: claude install-skill wahidyankf/ose-primer
# F# Coding Standards
## Purpose
Progressive disclosure of F# coding standards for agents writing F# code.
**Authoritative Source**: [docs/explanation/software-engineering/programming-languages/f-sharp/README.md](../../../docs/explanation/software-engineering/programming-languages/f-sharp/README.md)
**Usage**: Auto-loaded for agents when writing F# code. Provides quick reference to idioms, best practices, and antipatterns.
## Prerequisite Knowledge
**IMPORTANT**: This skill provides **demo-specific style guides**, not educational tutorials.
**You MUST understand F# fundamentals before using these standards.** Complete the demo F# learning path first:
**What this skill covers**: demo naming conventions, framework choices, repository-specific patterns, how to apply F# knowledge in THIS codebase.
**What this skill does NOT cover**: F# syntax, language fundamentals, generic patterns (those are in crud-fs-ts-nextjs).
## Quick Standards Reference
### Naming Conventions
**Modules/Types/DUs**: PascalCase - `ZakatCalculator`, `MurabahaContract`, `PaymentResult`
**Functions/Values**: camelCase - `calculateZakat`, `totalAmount`, `validateContract`
**DU Cases**: PascalCase - `Due`, `BelowNisab`, `ValidationError`
**Predicate functions**: `isValid`, `hasPayments` (boolean-returning functions prefixed with `is`/`has`)
### Discriminated Unions for Domain Modeling
```fsharp
// CORRECT: DU for domain states (exhaustive)
type ZakatResult =
| Due of amount: decimal
| Be