Resource
Callable
Type parameters
- T: UnknownResource
Parameters
packageName: string
The name of the package under which the resource is registered. Selecting a unique package name helps avoid collisions between same resource class names across different libraries. You will reuse the same package name throughout your library for different Octo components you create.
resourceName: string
a string that uniquely represents the name of the resource.
schema: Constructable<ResourceSchema<T>>
The schema of the resource.
Returns (constructor: any) => void
The decorated class.
Parameters
constructor: any
Returns void
A
@Resource
is a class decorator and must be placed on top of a class representing a resource.Decorators
Definition of Resources.