Skip to content

Cursor plugin specification and official plugins

TypeScript

Fix prohibited rule frontmatter: replace description+alwaysApply:false with alwaysApply:true

ericzakariasson0f081da07c59
diff --git a/code-review/rules/regression-risk-checklist.mdc b/code-review/rules/regression-risk-checklist.mdc
new file mode 100644
index 00000000..192558ff
--- /dev/null
+++ b/code-review/rules/regression-risk-checklist.mdc
@@ -0,0 +1,12 @@
+---
+alwaysApply: true
+---
+
+# Regression Risk Checklist
+
+1. Confirm API contracts and response shapes remain backward compatible.
+2. Validate migration and rollout safety for schema/config changes.
+3. Check for hidden side effects in shared utilities and core paths.
+4. Verify error-handling behavior remains explicit and user-safe.
+5. Ensure changed code paths are covered by tests, including edge cases.
+6. Flag missing observability for high-impact changes.
diff --git a/code-review/rules/security-review-checklist.mdc b/code-review/rules/security-review-checklist.mdc
new file mode 100644
index 00000000..61daeca8
--- /dev/null
+++ b/code-review/rules/security-review-checklist.mdc
@@ -0,0 +1,12 @@
+---
+alwaysApply: true
+---
+
+# Security Review Checklist
+
+1. Validate and sanitize untrusted input at trust boundaries.
+2. Confirm authorization checks exist for sensitive actions and resource access.
+3. Check for unsafe dynamic execution patterns (shell, SQL, template rendering).
+4. Ensure secrets are never hardcoded or logged.
+5. Verify security-relevant errors do not leak sensitive internals.
+6. Prefer safe defaults and fail-closed behavior for permission checks.
diff --git a/data-science/rules/analysis-quality-gates.mdc b/data-science/rules/analysis-quality-gates.mdc
new file mode 100644
index 00000000..db719dc0
--- /dev/null
+++ b/data-science/rules/analysis-quality-gates.mdc
@@ -0,0 +1,12 @@
+---
+alwaysApply: true
+---
+
+# Analysis Quality Gates
+
+1. Validate metric definitions and denominators against the business question.
+2. Check data freshness, missingness, duplicates, and join key integrity before interpretation.
+3. Confirm headline findings across key segments and plausible alternative cuts.
+4. Quantify uncertainty and practical significance, not only absolute differences.
+5. Call out confounders, bias risks, and assumptions that may limit conclusions.
+6. Provide an evidence-backed recommendation with clear decision risk.
diff --git a/data-science/rules/notebook-and-analysis-formatting.mdc b/data-science/rules/notebook-and-analysis-formatting.mdc
new file mode 100644
index 00000000..652a8621
--- /dev/null
+++ b/data-science/rules/notebook-and-analysis-formatting.mdc
@@ -0,0 +1,12 @@
+---
+alwaysApply: true
+---
+
+# Notebook and Analysis Formatting
+
+1. Start analysis with a short objective, metric definitions, and time window.
+2. Keep notebook cells focused and ordered; one analytical intent per cell with clear headings.
+3. Label every chart and table with title, units, denominator, and filter context.
+4. Keep outputs concise; summarize large intermediate data instead of dumping full frames.
+5. Prefer consistent naming and formatting in notebooks and scripts (for example, snake_case and explicit column names).
+6. End with a brief findings, caveats, and next steps section.
diff --git a/documentation/rules/docs-quality-standards.mdc b/documentation/rules/docs-quality-standards.mdc
new file mode 100644
index 00000000..33c61ce2
--- /dev/null
+++ b/documentation/rules/docs-quality-standards.mdc
@@ -0,0 +1,11 @@
+---
+alwaysApply: true
+---
+
+# Documentation Quality Standards
+
+1. Start with prerequisites and intended audience.
+2. Include runnable examples and expected outcomes.
+3. Keep terminology consistent with code and APIs.
+4. Document failure modes and troubleshooting steps.
+5. Prefer concise task-oriented structure over long narrative.
diff --git a/frontend/rules/accessibility-and-ux.mdc b/frontend/rules/accessibility-and-ux.mdc
new file mode 100644
index 00000000..81e5832d
--- /dev/null
+++ b/frontend/rules/accessibility-and-ux.mdc
@@ -0,0 +1,11 @@
+---
+alwaysApply: true
+---
+
+# Accessibility and UX Guardrails
+
+1. Ensure all interactive controls are keyboard accessible.
+2. Use semantic elements and proper ARIA labels when needed.
+3. Provide clear focus states and visible error messaging.
+4. Verify color contrast and avoid color-only status indicators.
+5. Handle loading, empty, error, and success states explicitly.
diff --git a/frontend/rules/frontend-performance-checks.mdc b/frontend/rules/frontend-performance-checks.mdc
new file mode 100644
index 00000000..59a0f8e9
--- /dev/null
+++ b/frontend/rules/frontend-performance-checks.mdc
@@ -0,0 +1,11 @@
+---
+alwaysApply: true
+---
+
+# Frontend Performance Checks
+
+1. Avoid unnecessary re-renders in hot UI paths.
+2. Keep bundle growth justified and measurable.
+3. Prefer lazy loading for heavy routes and components.
+4. Optimize expensive list rendering and memoization boundaries.
+5. Track performance regressions with concrete before/after evidence.
diff --git a/planning/rules/planning-quality-gates.mdc b/planning/rules/planning-quality-gates.mdc
new file mode 100644
index 00000000..720232fc
--- /dev/null
+++ b/planning/rules/planning-quality-gates.mdc
@@ -0,0 +1,11 @@
+---
+alwaysApply: true
+---
+
+# Planning Quality Gates
+
+1. Scope is explicit and out-of-scope is documented.
+2. Milestones are dependency-aware and testable.
+3. Risks and assumptions are listed with mitigation paths.
+4. Each milestone has acceptance criteria.
+5. Unknowns are converted into discovery tasks.