Either<NotFound, User>Failures
The error is part of the signature. Dropping the result without handling it is a lint error.
Agents
A coding agent stops at whatever compiles. functype puts more into the types, lints what types can't say, and tells the agent what to write instead.
users.save returns an Either, so a failed save is a value, not a throw. Drop it and TypeScript says nothing: the user is welcomed whether or not the save worked.
validate_code runs the compiler and functype's lint preset, and the error tells the agent what to write instead.
Save the new user, then welcome them.
✗ Line 8: This result is dropped, so a failure in it is silently ignored. Check isLeft() / isFailure(), fold it, or return it.functype/no-floating-result
✓ PASSED. The code is type-correct and passes the lint preset.
Strict TypeScript already catches a value that might be missing. It can't see a thrown error, or what an effect needs before it runs. functype puts those in the types too, so the compiler checks an agent's error handling, not only its spelling.
Either<NotFound, User>The error is part of the signature. Dropping the result without handling it is a lint error.
IO<Users, DbError, User>What it needs, how it fails, and nothing runs until you run it. Run it without its services and the compiler says: "Provide these services first, with provideLayer or provideService".
Option<User>Like strict null checks, but chainable: an agent can't read .name off a user that might not be there. It handles None or the code doesn't compile.
The escape hatches are guarded too. Rust has unsafe. TypeScript has null, throw and .orThrow(), and functype's lint preset reports each one unless the code marks it as a real boundary.
developers are shifting toward typed languages that make agent-assisted coding more reliable in production, as TypeScript became its most-used language.GitHub, Octoverse 2025
reduces compilation errors by more than half.Mündler et al., 2025
The plugin installs functype's skills and the MCP server together.
/plugin marketplace add jordanburke/functype
/plugin install functypeCursor, Windsurf and other clients that read an mcpServers config: add the server there.
{
"mcpServers": {
"functype": {
"command": "npx",
"args": ["-y", "functype-mcp-server"]
}
}
}The preset the MCP server runs, in your build, so CI holds the agent to it too. Its type-aware rules need parserOptions.projectService.
npm i -D eslint-plugin-functypeimport functype from "eslint-plugin-functype"
export default [
functype.configs.recommended,
functype.configs.tests,
]The whole library as text, for a model that can fetch a URL but runs no tools.
https://functype.org/llms.txt # an index
https://functype.org/llms-full.txt # everythingsearch_docsEvery type and its interfaces, or a keyword search.
get_type_apiOne type's full API: constructors, methods and what each returns.
get_interfacesThe interface hierarchy: Functor, Monad, Foldable and the rest.
validate_codeType-checks a snippet, then lints it with the recommended preset.
set_functype_versionSwitches the docs and the checker to the version your project uses.
Details and example output: the MCP server page.
Every rule is an error or off. An agent fixes what fails its build and passes over a warning, so a rule that isn't reliable stays off until it is.
A rule turns on once it's right on real code: about 95–99% of the time, with its known kinds of false alarm closed rather than left to warn.
Every message names the fix. "Call it: head()" is an instruction an agent can follow in one edit.
functype/no-floating-io0 false positives across about 1,340 IO-typed calls in five codebases.functype/no-array-mutation91 hits across five consumers, every one a real in-place mutation.functype/no-uncalled-method0 hits on 1,126 files of seven codebases. On supabase-typed-query's code from before its 2.0 port, it reports the Option(list.head) that port fixed.functype/no-serialize-container4 hits on one API, each a bug that project then fixed by hand.functype/no-container-mutation0 hits on 1,128 files of seven codebases, 343 of them tests, and every write planted through a cast is reported.Every rule, with its options and measurements: the ESLint page.