Skip to content

@nhtio/lucid-resourceful

A decorator-driven AdonisJS library that lets you annotate Lucid ORM models with metadata to automatically generate CRUD controllers, validation rules, OpenAPI schemas, and a unified query interface.

Variables

VariableDescription
resourcefulRouterMacro-
versionThe current version of the package.

Functions

FunctionDescription
resourcefulBelongsToDecorator to define a resourceful belongsTo relationship on a Lucid model property.
resourcefulColumnDecorator to define a resourceful column on a Lucid model property. Applies validation, metadata, and Lucid column options.
resourcefulComputedDecorator to define a resourceful computed accessor on a Lucid model property. Applies validation, metadata, and Lucid computed options.
resourcefulHasManyDecorator to define a resourceful hasMany relationship on a Lucid model property.
resourcefulHasManyThroughDecorator to define a resourceful hasManyThrough relationship on a Lucid model property.
resourcefulHasOneDecorator to define a resourceful hasOne relationship on a Lucid model property.
resourcefulManyToManyDecorator to define a resourceful manyToMany relationship on a Lucid model property.
withResourcefulCreates a mixin that adds resourceful CRUD functionality to Lucid models.

References

definitions

Renames and re-exports @nhtio/lucid-resourceful/definitions


errors

Renames and re-exports @nhtio/lucid-resourceful/errors


odataRouterMacro

Re-exports odataRouterMacro