-
Notifications
You must be signed in to change notification settings - Fork 17
CheerpJ filesystem tutorial #264
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
||
To follow this tutorial, you'll need: | ||
|
||
- [Download the template project](/docs/cheerpj3/tutorials/CheerpJFilesystemTutorial.zip) and unzip it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not in general very convinced about shipping templates, but if we have to do so please use repos. Keeping zips updated is expensive in the long run.
In terms of which repo to use we should try to avoid making many new ones, already too many require manual synchronization alerady. Let's put everything in cheerpj-meta |
|
||
CheerpJ's virtual filesystem has several key mounting points that behave differently: | ||
|
||
- **`/files/`**: This is a **temporary, in-memory filesystem**. Files written here are accessible by your Java application but are not persistent across sessions or page reloads. This is useful for temporary files or data generated during a single user session that needs to be downloaded. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is wrong, the /files mounting point is persistent and will only be cleared if the user clears out indexdb manually. Our own docs explain it -> https://cheerpj.com/docs/guides/File-System-support#files-mount-point
2c08d98
to
1318c2e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As mentioned in slack, let's shorten the code examples a bit for now and add a single example later on. Left some notes regarding the content.
1318c2e
to
aa3745b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi guys, I think there is a bit of confusion on where this piece of information should go.
First, let me clarify the difference between a guide and a tutorial under the framework we are using:
- Guides: Explain an element of the functionality of the technology, with different small generic examples.
- Tutorial: beginning to end, step by step small use-case project with a tangible result.
It seems to me that the best place to add this info is as an extension of the existing Files and Filesystem guide.
@GabrielaReyna I agree that this content makes more sense as a guide, but I think it should be it's own guide. The existing one mostly explains the architecture and briefly mentions some APIs that can be used to interact with the virtual file system. We could rename the existing guide to |
Good point Elisabeth, let's do the following:
|
Filesystem tutorial
aa3745b
to
9d0e9f1
Compare
Hi, I have updated the files as per your last comments @epanholz @GabrielaReyna |
Filesystem tutorial