no-network-fast-result
errorType-aware
Disallows FastResult in contracts passed to Networking.createFunction from @flamework/networking.
Rule details Problem
Section titled “Rule details Problem ”FastResult is a LuaTuple, which cannot cross a Flamework network boundary. The rule resolves imported and aliased
FastResult types, including nested response types such as Promise<FastResult>.
It only checks RPC contracts. Local helpers may still return FastResult normally.
Examples
Section titled “Examples”Incorrect
import { Networking } from "@flamework/networking";
interface ClientToServer { warp: { toCFrame: () => FastResult };}
Networking.createFunction<ClientToServer, undefined>();Correct
import { Networking } from "@flamework/networking";
interface ClientToServer { warp: { toCFrame: () => { success: boolean; message?: string } };}
Networking.createFunction<ClientToServer, undefined>();Options
Section titled “Options”| Option | Type | Default | Description |
|---|---|---|---|
checkParameters |
boolean |
false |
Also report FastResult in RPC parameter types. |
export default [ { rules: { "cease-nonsense/no-network-fast-result": ["error", { checkParameters: true }], }, },];