Update docs to use async/await (#667)
* [docs] update readme and examples to use async/await * [apis] regenerate (including updated examples)
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
.Create a document
|
||||
[source,js]
|
||||
---------
|
||||
client.create({
|
||||
await client.create({
|
||||
index: 'myindex',
|
||||
type: 'mytype',
|
||||
id: '1',
|
||||
@ -12,7 +12,5 @@ client.create({
|
||||
published_at: '2013-01-01',
|
||||
counter: 1
|
||||
}
|
||||
}, function (error, response) {
|
||||
// ...
|
||||
});
|
||||
---------
|
||||
---------
|
||||
|
||||
Reference in New Issue
Block a user