agentleFS
aws-solutionsaws-solutions/konductor/skills/frontend-review/SKILL.md

frontend-review

Skill11 starsChanged 50 days agoApache-2.0View on GitHub

Reviews frontend code changes for Cloudscape compliance, React Hook Form patterns, TypeScript type safety, and test quality. Use after implementing frontend changes to catch issues before code review. Produces CRITICAL/IMPORTANT/SUGGESTION findings.

9 other projects use a version of this.

Adopted by

Most recently taken up by

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 3 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 8 edited versions we read keep these.

  • 3

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use this skill when:

    line 16
  2. Distinctive:

    Test passes only due to implementation detail coupling

    line 79
  3. Distinctive:

    Test assertions check existence but not actual values

    line 87

“Common” is measured: kept by at least 6 in 10 of the 8 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Frontend Review

Overview

Reviews frontend code with a critical eye across Cloudscape compliance, form patterns, type safety, component quality, and test coverage. Provides direct, unbiased assessment — calls out pattern violations, unnecessary complexity, and missing test coverage.

Usage

Use this skill when:

  • Reviewing frontend changes before submitting a code review
  • Validating Cloudscape component compliance
  • Checking React Hook Form + Zod pattern adherence
  • Assessing TypeScript type safety and test coverage

Core Concepts

Review Focus Areas

Pattern compliance (React Hook Form + Zod, useFormContext, FormProvider), Cloudscape compliance (no native HTML, no inline styles), type safety (no any, explicit useForm<T>() types), code quality (memoized handlers, stable layouts, no unnecessary wrappers), and test quality (actual value assertions, error state coverage).

Review Checklist

Pattern Compliance

  • React Hook Form used — not custom state hooks
  • Zod validation used — not manual validation
  • Form sub-components use useFormContext — no prop drilling
  • Wizard pages wrapped in FormProvider

Cloudscape Compliance

  • No native HTML elements (<div>, <span>, <input>, <button>, <a>)
  • No inline styles (style={{}})
  • Box used instead of <div> or <span>
  • KeyValuePairs for label-value display
  • SpaceBetween for spacing
  • Fixed column counts in ColumnLayout
  • FormField wraps all form inputs

Type Safety

  • No any types in production code
  • Explicit types on useForm<FormType>() calls
  • TypeScript utility types used correctly (Pick, Omit, Partial)
  • No redundant type assertions

Code Quality

  • No unused code or imports
  • No unnecessary wrapper components
  • Event handlers memoized with useCallback
  • Imperative array building for 3+ conditional items (not ternary chains)
  • Stable layouts (fixed column counts)

Testing

  • Helper functions have unit tests
  • Form components have component tests
  • Test assertions check actual values (not just existence)
  • Error states tested
  • Edge cases covered

Quality Gate

CRITICAL (blocks approval):

  • Native HTML element used instead of Cloudscape component
  • Inline style used (style={{}})
  • Form state managed with useState instead of React Hook Form
  • any type in production code
  • Test passes only due to implementation detail coupling

IMPORTANT (should fix):

  • Missing explicit type on useForm call
  • Hardcoded validation message instead of constraint constant
  • Event handler not memoized (causes unnecessary re-renders)
  • Dynamic column count in ColumnLayout (causes layout shift)
  • Test assertions check existence but not actual values

SUGGESTION:

  • Could extract repeated form field pattern into reusable component
  • Could add missing edge case tests
  • Could strengthen error state test coverage

Present findings as: CRITICAL → IMPORTANT → SUGGESTION. Ask: "Fix these issues? [y/n]" — unless scope_confirmed is true, in which case report all the findings and leave fixing to the caller, without asking.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.