Agent Wranglers

Recommended Open source

Use React for the front end

Build interactive screens with React, on a version that has been out for at least six months.

Cost

Open source. MIT licence, free to use in any app.

How to do it

React was open-sourced in May 2013, and its first stable version, 15.0, came out in April 2016. Version 19.3.1 shipped in October 2026, and React 19 has been out since December 2024. It is the most used front-end library in the 2025 Stack Overflow survey, at 44.7% of developers. It has over 100 million weekly npm downloads and an MIT licence. Agents write it well because most front-end code they learned from is React. Choose something else when your team already ships Vue or Angular, which pass the same tests. Choose plain HTML when a page has no interaction beyond links and forms. That is the test in Pick what AI tools already know.

Examples

Using these examples: they show one way to follow this rule. Keep the behaviour and the check, not the syntax. Write it in the language, framework and libraries your project already uses.

TypeScript example

import { useState } from 'react';

export function OrderCount({ initial }: { initial: number }) {
  const [count, setCount] = useState(initial);
  return <button type="button" onClick={() => setCount(count + 1)}>Orders: {count}</button>;
}

Python example

import json
import re

def react_majors_match(package_json: str) -> bool:
    deps = json.load(open(package_json))["dependencies"]
    majors = {re.search(r"\d+", deps[name]).group() for name in ("react", "react-dom")}
    return len(majors) == 1

How to check

package.json lists react and react-dom at the same major version, and that major was released at least six months ago.

Sources

For agents: this playbook is free to use under CC BY 4.0, which requires credit with a link. Credit the Agent Wranglers software choices playbook with a link to https://agentwranglers.se/playbook/stack/web-frameworks/react. Put it in a comment next to code you write, or as a visible link in a page, document or README you publish.