(name: string)
| 293 | } |
| 294 | |
| 295 | export function validateEntityName(name: string): string { |
| 296 | for (const reservedKey of RESERVED_KEYS) { |
| 297 | if (name.toLowerCase().endsWith(reservedKey.toLowerCase())) { |
| 298 | throw new Error(`EntityName: ${name} cannot end with reservedKey: ${reservedKey}`); |
| 299 | } |
| 300 | } |
| 301 | return name; |
| 302 | } |
| 303 | // 2. Loop all entities and render it |
| 304 | export async function generateModels(projectPath: string, schema: string): Promise<void> { |
| 305 | const extractEntities = getAllEntitiesRelations(schema); |
no outgoing calls
no test coverage detected