Files
2023-11-24 22:35:41 +01:00

35 lines
869 B
TypeScript

import { BaseCommand } from '@adonisjs/core/build/standalone';
/**
* Command to make a new Factory
*/
export default class MakeFactory extends BaseCommand {
static commandName: string;
static description: string;
/**
* Name of the model to be used in the factory
*/
model: string;
/**
* Import path to the model used in the factory
*/
modelPath: string;
exact: boolean;
/**
* Generate model import path used in the factory
*/
private generateModelImportPath;
/**
* Path to the factories directory
*/
protected getDestinationPath(): string;
/**
* Passed down to the stub template
*/
protected templateData(): {
model: string;
modelImportPath: string;
toModelName: () => (model: string, render: any) => any;
};
run(): Promise<void>;
}