/*! * Copyright (c) Microsoft Corporation and contributors. All rights reserved. * Licensed under the MIT License. */ import type { IFluidHandle } from "@fluidframework/core-interfaces"; import type { Jsonable } from "./jsonable.js"; /** * Used to constrain a type 'T' to types that Fluid can intrinsically serialize. Produces a * compile-time error if `T` contains non-serializable members. * * @remarks * See Jsonable for caveats regarding serialization of `undefined`, non-finite numbers, * and circular references. * * Important: `T extends Serializable` is generally incorrect. * (Any value of `T` extends the serializable subset of itself.) * * @example Typical usage * * ```typescript * function serialize(value: Serializable) { ... } * ``` * @legacy @beta */ export type Serializable = Jsonable;