Function normalizeOptions

  • Internal

    Normalizes options

    Parameters

    • options: undefined | WriteFileOptions | (EncodingOption & { flag?: OpenMode | undefined; })

      options to normalize

    • encoding: null | BufferEncoding = 'utf8'

      default encoding

    • flag: string

      default flag

    • mode: number = 0

      default mode

    Returns {
        encoding?: BufferEncoding | null;
        flag: string;
        mode: number;
    }

    • Optionalencoding?: BufferEncoding | null
    • flag: string
    • mode: number