FrostEntity
@frost/frost-web / Exports / FrostEntity
Function: FrostEntity
▸ FrostEntity(options
): <T>(constructor
: T
) => void
This decorator allows you to declare a class as a node in FirebaseDB and provide the path for it
This decorator is used to mark classes that extend FrostObject
Decorator
Example
@FrostEntity({collectionPath : "/users"})
class User extends FrostObject {
}
Parameters
Name | Type | Description |
---|---|---|
options | FrostEntityDecoratorOptions | Entity Options |
Returns
fn
▸ <T
>(constructor
): void
Type parameters
Name | Type |
---|---|
T | extends (...args : any []) => FrostObject <{ id? : string }> |
Parameters
Name | Type |
---|---|
constructor | T |
Returns
void