fs-writefile-promise

WebJar for fs-writefile-promise

Лицензия

Лицензия

ISC
Группа

Группа

org.webjars.npm
Идентификатор

Идентификатор

fs-writefile-promise
Последняя версия

Последняя версия

1.0.3
Дата

Дата

Тип

Тип

jar
Описание

Описание

fs-writefile-promise
WebJar for fs-writefile-promise
Ссылка на сайт

Ссылка на сайт

https://www.webjars.org
Система контроля версий

Система контроля версий

https://github.com/ahmadnassri/node-fs-writefile-promise

Скачать fs-writefile-promise

Как подключить последнюю версию

<!-- https://jarcasting.com/artifacts/org.webjars.npm/fs-writefile-promise/ -->
<dependency>
    <groupId>org.webjars.npm</groupId>
    <artifactId>fs-writefile-promise</artifactId>
    <version>1.0.3</version>
</dependency>
// https://jarcasting.com/artifacts/org.webjars.npm/fs-writefile-promise/
implementation 'org.webjars.npm:fs-writefile-promise:1.0.3'
// https://jarcasting.com/artifacts/org.webjars.npm/fs-writefile-promise/
implementation ("org.webjars.npm:fs-writefile-promise:1.0.3")
'org.webjars.npm:fs-writefile-promise:jar:1.0.3'
<dependency org="org.webjars.npm" name="fs-writefile-promise" rev="1.0.3">
  <artifact name="fs-writefile-promise" type="jar" />
</dependency>
@Grapes(
@Grab(group='org.webjars.npm', module='fs-writefile-promise', version='1.0.3')
)
libraryDependencies += "org.webjars.npm" % "fs-writefile-promise" % "1.0.3"
[org.webjars.npm/fs-writefile-promise "1.0.3"]

Зависимости

compile (2)

Идентификатор библиотеки Тип Версия
org.webjars.npm : mkdirp-promise jar [1.0.0,2)
org.webjars.npm : pinkie-promise jar [1.0.0,2)

Модули Проекта

Данный проект не имеет модулей.

fs.writeFile Promise

License version Build Status

Promise version of fs.writeFile:
Asynchronously writes data to a file, replacing the file if it already exists.

Install

npm install fs-writefile-promise

API

write(filename, data [, options])

  • filename: String
  • data String or Buffer
  • options: Object

Return: Object (Promise)

When it finishes, it will be fulfilled with the file name that was written to.

When it fails, it will be rejected with an error as its first argument.

write('/tmp/foo', 'bar')
  .then(filename => console.log(filename)) //=> '/tmp/foo'
  .catch(err => console.error(err))

options

The option object will be directly passed to fs.writeFile.


Author: Ahmad Nassri • Github: @ahmadnassri • Twitter: @AhmadNassri

Версии библиотеки

Версия
1.0.3