Back to Firebase Js Sdk

AnyOfSchema class

docs-devsite/ai.anyofschema.md

12.12.11.5 KB
Original Source

Project: /docs/reference/js/_project.yaml Book: /docs/reference/_book.yaml page_type: reference

{% comment %} DO NOT EDIT THIS FILE! This is generated by the JS SDK team, and any local changes will be overwritten. Changes should be made in the source code at https://github.com/firebase/firebase-js-sdk {% endcomment %}

AnyOfSchema class

Schema class representing a value that can conform to any of the provided sub-schemas. This is useful when a field can accept multiple distinct types or structures.

<b>Signature:</b>

typescript
export declare class AnyOfSchema extends Schema 

<b>Extends:</b> Schema

Constructors

ConstructorModifiersDescription
(constructor)(schemaParams)Constructs a new instance of the <code>AnyOfSchema</code> class

Properties

PropertyModifiersTypeDescription
anyOfTypedSchema<!-- -->[]

AnyOfSchema.(constructor)

Constructs a new instance of the AnyOfSchema class

<b>Signature:</b>

typescript
constructor(schemaParams: SchemaParams & {
        anyOf: TypedSchema[];
    });

Parameters

ParameterTypeDescription
schemaParamsSchemaParams & { anyOf: TypedSchema<!-- -->[]; }

AnyOfSchema.anyOf

<b>Signature:</b>

typescript
anyOf: TypedSchema[];