Lucid Parser

Parse Lucid models to retrieve properties types information

Lucid Parser is a tool to retrieve Lucid models properties information by parsing the AST Tree.

This become usefull when types information provided by Typescript metadatas are not sufficient as Lucid Parser is able to retrieve type information for nullable, optional and array properties.

Installation

npm install @foadonis/lucid-parser

Usage

import { parseModel } from '@foadonis/lucid-parser'
 
const { columns, computed } = parseModel(import.meta.resolve('#models/user'))

On this page