diff --git a/.cursor/skills/agoda-ioc-dependency-injection/SKILL.md b/.cursor/skills/agoda-ioc-dependency-injection/SKILL.md index 8f07f22..3faf59f 100644 --- a/.cursor/skills/agoda-ioc-dependency-injection/SKILL.md +++ b/.cursor/skills/agoda-ioc-dependency-injection/SKILL.md @@ -5,6 +5,16 @@ description: Enforces use of Agoda.IoC attribute-based dependency injection regi # Agoda.IoC for Dependency Injection +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + Use [Agoda.IoC](https://github.com/agoda-com/Agoda.IoC) attribute-based registration in all C# **application** projects. Do NOT use it in **library/SDK** projects — libraries should not force a DI framework on their consumers. ## Why Attribute-Based Registration diff --git a/.cursor/skills/api-response-for-browser/SKILL.md b/.cursor/skills/api-response-for-browser/SKILL.md index 0f5f2a2..4cd0d38 100644 --- a/.cursor/skills/api-response-for-browser/SKILL.md +++ b/.cursor/skills/api-response-for-browser/SKILL.md @@ -5,6 +5,16 @@ description: Enforces efficient API endpoint design when serving data to browser # API Response Design for Browser Clients +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Rule **Shape data on the server to match what the page needs. Minimise the number of HTTP requests per page.** diff --git a/.cursor/skills/csharp-async-patterns/SKILL.md b/.cursor/skills/csharp-async-patterns/SKILL.md index 889735e..e807af5 100644 --- a/.cursor/skills/csharp-async-patterns/SKILL.md +++ b/.cursor/skills/csharp-async-patterns/SKILL.md @@ -10,6 +10,16 @@ description: >- # C# Async/Await Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Always use async API versions Prefer the async version of any method when it exists. No downsides. diff --git a/.cursor/skills/csharp-code-style/SKILL.md b/.cursor/skills/csharp-code-style/SKILL.md index 4ceb0cc..f85c4f5 100644 --- a/.cursor/skills/csharp-code-style/SKILL.md +++ b/.cursor/skills/csharp-code-style/SKILL.md @@ -10,6 +10,16 @@ description: >- # C# Code Style Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Naming conventions Follow Resharper defaults for consistency. diff --git a/.cursor/skills/csharp-collections/SKILL.md b/.cursor/skills/csharp-collections/SKILL.md index 03ddebe..030e0c3 100644 --- a/.cursor/skills/csharp-collections/SKILL.md +++ b/.cursor/skills/csharp-collections/SKILL.md @@ -11,6 +11,16 @@ description: >- # C# Collection Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Do not use Arrays No public method may return an Array (except `byte[]` for binary data). Use `List`, `IEnumerable`, `Dictionary`, `HashSet` instead. Arrays are only acceptable internally for performance-critical or raw binary scenarios. diff --git a/.cursor/skills/csharp-configuration/SKILL.md b/.cursor/skills/csharp-configuration/SKILL.md index 931343b..6da15ee 100644 --- a/.cursor/skills/csharp-configuration/SKILL.md +++ b/.cursor/skills/csharp-configuration/SKILL.md @@ -10,6 +10,16 @@ description: >- # C# Configuration Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Config files: only for Consul bootstrap and secrets For new projects, `web/app.config` should only contain: diff --git a/.cursor/skills/csharp-exception-handling/SKILL.md b/.cursor/skills/csharp-exception-handling/SKILL.md index 40c01b2..c2aa321 100644 --- a/.cursor/skills/csharp-exception-handling/SKILL.md +++ b/.cursor/skills/csharp-exception-handling/SKILL.md @@ -10,6 +10,16 @@ description: >- # C# Exception Handling Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Be specific in what you catch Catch the most specific exception type possible. Never catch `System.Exception` when you only handle a specific scenario. diff --git a/.cursor/skills/csharp-extension-methods/SKILL.md b/.cursor/skills/csharp-extension-methods/SKILL.md index ca917f4..40ae0fd 100644 --- a/.cursor/skills/csharp-extension-methods/SKILL.md +++ b/.cursor/skills/csharp-extension-methods/SKILL.md @@ -9,6 +9,16 @@ description: >- # C# Extension Method Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## When to write an extension method Only when at least one is true: diff --git a/.cursor/skills/csharp-gui-testing/SKILL.md b/.cursor/skills/csharp-gui-testing/SKILL.md index 541b00c..3bfc910 100644 --- a/.cursor/skills/csharp-gui-testing/SKILL.md +++ b/.cursor/skills/csharp-gui-testing/SKILL.md @@ -9,6 +9,16 @@ description: >- # C# GUI Testing Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Use CSS selectors, not XPath XPath is unfamiliar to most developers and adds noise. Since we identify elements with `data-selenium`, CSS selectors are sufficient. diff --git a/.cursor/skills/csharp-logging/SKILL.md b/.cursor/skills/csharp-logging/SKILL.md index 751144f..a63d50b 100644 --- a/.cursor/skills/csharp-logging/SKILL.md +++ b/.cursor/skills/csharp-logging/SKILL.md @@ -8,6 +8,16 @@ description: >- # C# Logging Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Log message guidelines - Short but relevant messages diff --git a/.cursor/skills/csharp-service-design/SKILL.md b/.cursor/skills/csharp-service-design/SKILL.md index fda7697..dddacf6 100644 --- a/.cursor/skills/csharp-service-design/SKILL.md +++ b/.cursor/skills/csharp-service-design/SKILL.md @@ -12,6 +12,16 @@ description: >- # C# Service Design Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Interfaces Only create an interface if: diff --git a/.cursor/skills/csharp-testing-strategy/SKILL.md b/.cursor/skills/csharp-testing-strategy/SKILL.md index e02640d..0128d39 100644 --- a/.cursor/skills/csharp-testing-strategy/SKILL.md +++ b/.cursor/skills/csharp-testing-strategy/SKILL.md @@ -5,6 +5,16 @@ description: Enforces the Honeycomb testing strategy for C# services. Prefer bla # C# Testing Strategy +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + This skill follows the **Honeycomb testing model**: the bulk of tests should be integration tests that exercise real behavior through the HTTP boundary, not unit tests of internal classes. Unit tests are reserved for pure helper/utility methods with no dependencies. ## Test Pyramid vs Honeycomb diff --git a/.cursor/skills/csharp-testing/SKILL.md b/.cursor/skills/csharp-testing/SKILL.md index e2df981..1bdc463 100644 --- a/.cursor/skills/csharp-testing/SKILL.md +++ b/.cursor/skills/csharp-testing/SKILL.md @@ -10,6 +10,16 @@ description: >- # C# Testing Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Why we test - Validate code does what we think it does diff --git a/.cursor/skills/csharp-web-structure/SKILL.md b/.cursor/skills/csharp-web-structure/SKILL.md index d3fab77..1f9a2b2 100644 --- a/.cursor/skills/csharp-web-structure/SKILL.md +++ b/.cursor/skills/csharp-web-structure/SKILL.md @@ -10,6 +10,16 @@ description: >- # C# Web Solution Structure Standards +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Presentation project ### View models / DTOs diff --git a/.cursor/skills/find-root-cause/SKILL.md b/.cursor/skills/find-root-cause/SKILL.md index 93397f4..2451ae4 100644 --- a/.cursor/skills/find-root-cause/SKILL.md +++ b/.cursor/skills/find-root-cause/SKILL.md @@ -5,6 +5,16 @@ description: Enforces root-cause analysis before fixing bugs or resolving errors # Find the Root Cause +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Core Rule **Never patch symptoms. Always find and fix the root cause.** Before writing any fix, trace the problem to its origin. A fix that suppresses the symptom without addressing why it happened will fail again — or worse, hide the real issue until it causes broader damage. diff --git a/.cursor/skills/no-browser-datetime/SKILL.md b/.cursor/skills/no-browser-datetime/SKILL.md index 7cd3fe2..75634e9 100644 --- a/.cursor/skills/no-browser-datetime/SKILL.md +++ b/.cursor/skills/no-browser-datetime/SKILL.md @@ -5,6 +5,16 @@ description: Enforces that Date objects and datetime types are never used in bro # No DateTime in the Browser +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Rule **Never use `Date` objects or datetime types in browser/frontend code.** diff --git a/.cursor/skills/no-test-code-in-production/SKILL.md b/.cursor/skills/no-test-code-in-production/SKILL.md index cdd4f29..2f385de 100644 --- a/.cursor/skills/no-test-code-in-production/SKILL.md +++ b/.cursor/skills/no-test-code-in-production/SKILL.md @@ -5,6 +5,16 @@ description: Enforces that mocks, stubs, fakes, and other test-only code are nev # No Test Code in Production +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Core Rule Never place mocks, stubs, fakes, spy implementations, or any test-only code in production source files. Test doubles belong exclusively in test files and test directories. diff --git a/.cursor/skills/preserve-existing-tests/SKILL.md b/.cursor/skills/preserve-existing-tests/SKILL.md index 01de41c..fb459ee 100644 --- a/.cursor/skills/preserve-existing-tests/SKILL.md +++ b/.cursor/skills/preserve-existing-tests/SKILL.md @@ -5,6 +5,16 @@ description: Prevents modification of existing tests and test data unless behavi # Preserve Existing Tests +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + ## Core Rule **Never modify existing tests or test data.** If existing tests fail after your changes, that is a signal you may have introduced a bug — not that the tests are wrong. diff --git a/.cursor/skills/react-component-layout/SKILL.md b/.cursor/skills/react-component-layout/SKILL.md index 91b0d46..2960667 100644 --- a/.cursor/skills/react-component-layout/SKILL.md +++ b/.cursor/skills/react-component-layout/SKILL.md @@ -5,6 +5,16 @@ description: Enforces that React component code mirrors the visual layout of the # React Component Layout +## Requirement levels (RFC 2119) + +The key words **MUST**, **MUST NOT**, **REQUIRED**, **SHALL**, **SHALL NOT**, **SHOULD**, **SHOULD NOT**, **RECOMMENDED**, **NOT RECOMMENDED**, **MAY**, and **OPTIONAL** in this document are to be interpreted as described in RFC 2119. + +Interpretation for contributors and reviewers: +- **MUST / MUST NOT**: non-negotiable requirement (blocking) +- **SHOULD / SHOULD NOT**: strong default; deviations require explicit rationale +- **MAY / OPTIONAL**: context-dependent choice + + Structure React code so that reading it feels like looking at the UI. A developer should be able to glance at the JSX and immediately see the same major sections, divisions, and hierarchy that appear on screen. ## Core Principles