From f12ef58c50e42a4e12db3406884d9dbf26390a3c Mon Sep 17 00:00:00 2001 From: Tillmann <28728469+tweidinger@users.noreply.github.com> Date: Mon, 26 Aug 2024 12:38:07 +0900 Subject: [PATCH 1/2] clarify rust side exposure --- src/content/docs/plugin/file-system.mdx | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/content/docs/plugin/file-system.mdx b/src/content/docs/plugin/file-system.mdx index d7c0250cb6..aefd0a4b5b 100644 --- a/src/content/docs/plugin/file-system.mdx +++ b/src/content/docs/plugin/file-system.mdx @@ -84,6 +84,14 @@ Install the fs plugin to get started. The fs plugin is available in both JavaScript and Rust. +:::note[Rust Exposure] + +The exposed API on the Rust side is only intended to manipulate the [Scope](#scopes) of the plugin but +does not expose any functional API to access the file system. Please use [`tokio::fs`](https://docs.rs/tokio/latest/tokio/fs/index.html) or the +[`std::fs`](https://doc.rust-lang.org/std/fs/index.html) for accessing the file system. + +::: + From 8a63c11a8642a2adbc5dc5a968e57f6606e4b598 Mon Sep 17 00:00:00 2001 From: Tillmann <28728469+tweidinger@users.noreply.github.com> Date: Tue, 27 Aug 2024 13:11:35 +0900 Subject: [PATCH 2/2] add mention of partial api exposure --- src/content/docs/plugin/file-system.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/content/docs/plugin/file-system.mdx b/src/content/docs/plugin/file-system.mdx index aefd0a4b5b..2e2acd7169 100644 --- a/src/content/docs/plugin/file-system.mdx +++ b/src/content/docs/plugin/file-system.mdx @@ -86,8 +86,8 @@ The fs plugin is available in both JavaScript and Rust. :::note[Rust Exposure] -The exposed API on the Rust side is only intended to manipulate the [Scope](#scopes) of the plugin but -does not expose any functional API to access the file system. Please use [`tokio::fs`](https://docs.rs/tokio/latest/tokio/fs/index.html) or the +The exposed API on the Rust side is mostly intended to manipulate the [Scope](#scopes) of the plugin. +It does expose some APIs to access the file system on mobile, but the recommendation is to use [`tokio::fs`](https://docs.rs/tokio/latest/tokio/fs/index.html) or the [`std::fs`](https://doc.rust-lang.org/std/fs/index.html) for accessing the file system. :::