Function writeFileSync

  • Returns undefined.

    If data is a plain object, it must have an own (not inherited) toStringfunction property.

    The mode option only affects the newly created file. See open for more details.

    For detailed information, see the documentation of the asynchronous version of this API: writeFile.

    Since

    v0.0.67

    Parameters

    • file: PathOrFileDescriptor

      filename or file descriptor

    • data: string | ArrayBufferLike | ArrayBufferView
    • Optional options: "fs".WriteFileOptions

    Returns void

  • Returns undefined.

    If data is a plain object, it must have an own (not inherited) toStringfunction property.

    The mode option only affects the newly created file. See open for more details.

    For detailed information, see the documentation of the asynchronous version of this API: writeFile.

    Since

    v0.0.67

    Parameters

    • file: PathOrFileDescriptor

      filename or file descriptor

    • data: string | ArrayBufferLike | ArrayBufferView
    • Optional options: "fs".WriteFileOptions

    Returns void

Generated using TypeDoc