Spyke

Syndicated from the fediverse. Read and engage on the original instance.

View original on lemmy.zip

How to do lazy-loading text from scrolling in vanilla js module?

Is there any js module for lazy-loading a files content? in vanilla js, (that a import via a script tag), so that if i scroll enough, it will send a request to the server for more of a files content, at a specific chunk of it, and the browser will add the rest of the content to the file viewer/editor

I am making a filebrowser, and so far i implemented navigating folders, uploading files, next I would like to make a file editor, so its not the html page itself I want lazy-loaded, I want a file to be lazy-loaded into the editor, again, so you scroll enough, and it will fetch the chunks from the server (i can figure out the backend bit, I would like it if it worked with multexjs or multipart in rust and I dont have to manually sort out file chunking but thats not a hard requirement.)

Alternative to modules would just be code i can use

View original on lemmy.zip
6
How to do lazy-loading text from scrolling in vanilla js module? | Spyke