Skip to content

Commit c268e8f

Browse files
committed
chore(doc): update readme
1 parent 03abf6f commit c268e8f

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

README.md

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Take a look at before and after
99
**Before:**
1010

1111
```lua
12-
client.request('workspace/executeCommand', cmd_info, function(err, res)
12+
request('workspace/executeCommand', cmd_info, function(err, res)
1313
if err then
1414
log.error(err)
1515
else
@@ -22,7 +22,7 @@ end, buffer)
2222

2323
```lua
2424
-- on error, statement will fail throwing an error just like any synchronous API
25-
local result = client.request('workspace/executeCommand', cmd_info, buffer)
25+
local result = request('workspace/executeCommand', cmd_info, buffer)
2626
log.debug(result)
2727
```
2828

@@ -88,3 +88,11 @@ runner(function()
8888
end)
8989
.run()
9090
```
91+
92+
### Output
93+
94+
```txt
95+
18:44:46 starting the execution
96+
18:44:48 success_result is: hello world
97+
18:44:50 parent error handler ...-async-await/lua/async/waits/wait_with_error_handler.lua:14: ...-async-await/lua/async/waits/wait_with_error_handler.lua:14: something went wrong
98+
```

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy