Skip to content

Commit 1e28d34

Browse files
oleiadecodebien
andauthored
Apply suggestions from code review
Co-authored-by: Ivan <[email protected]>
1 parent 6f4e675 commit 1e28d34

File tree

1 file changed

+2
-2
lines changed
  • docs/sources/next/javascript-api/k6-experimental/fs

1 file changed

+2
-2
lines changed

docs/sources/next/javascript-api/k6-experimental/fs/open.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ weight: 20
66

77
# open
88

9-
The `open` function opens a file and returns a promise that resolves to a [File](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/k6-experimental/fs/file) instance. This function loads the file into shared memory space accessible by all Virtual Users (VUs). This approach significantly reduces the memory footprint, enabling the handling of large files without overwhelming memory resources.
9+
The `open` function opens a file and returns a promise that resolves to a [File](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/k6-experimental/fs/file) instance. This function loads the file into shared memory space accessible by all Virtual Users (VUs). This approach significantly ~reduces the memory footprint~, enabling the handling of large files without overwhelming memory resources.
1010

1111
### Asynchronous Nature
1212

13-
It's important to note that `open` is asynchronous and returns a [Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise). Due to k6's current limitation with the init context (which doesn't support asynchronous functions directly), you need to use an asynchronous wrapper like this:
13+
It's important to note that `open` is asynchronous and returns a [Promise](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise). Due to k6's current limitation with the Init context (which doesn't support asynchronous functions directly), you need to use an asynchronous wrapper like this:
1414

1515
{{< code >}}
1616

0 commit comments

Comments
 (0)