AdonisJS API
    Preparing search index...
    GeneratedStub:
        | GeneratedStubBase & { status: "skipped"; skipReason: string }
        | GeneratedStubBase & { status: "created"; skipReason: null }
        | GeneratedStubBase & { status: "force_created"; skipReason: null }

    Represents the result of stub generation after attempting to write to disk. Indicates whether the file was created, skipped, or force-created with reasons.

    Type Declaration

    • GeneratedStubBase & { status: "skipped"; skipReason: string }
      • status: "skipped"

        File generation was skipped

      • skipReason: string

        Reason why the file was skipped

    • GeneratedStubBase & { status: "created"; skipReason: null }
      • status: "created"

        File was successfully created

      • skipReason: null
    • GeneratedStubBase & { status: "force_created"; skipReason: null }
      • status: "force_created"

        File was overwritten because force option was enabled

      • skipReason: null
    // File created successfully
    const result: GeneratedStub = {
    status: 'created',
    skipReason: null,
    contents: '...',
    destination: '/path/to/file.ts',
    attributes: {}
    }
    // File already exists and force was not enabled
    const result: GeneratedStub = {
    status: 'skipped',
    skipReason: 'File already exists',
    contents: '...',
    destination: '/path/to/file.ts',
    attributes: {}
    }