-
-
Notifications
You must be signed in to change notification settings - Fork 148
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
Online Preview (ZIM reading over HTTP) #659
Comments
It will be important to ensure that the server accepts the Range header: https://developer.mozilla.org/en-US/docs/Web/HTTP/Range_requests . |
This proposal needs more thinking IMHO. First, we need to keep in mind that we need to replace our custom javascript backend implementation with an emscripten compiled version of libzim/kiwix-lib. In their current forms, these libraries do not support reading ZIM files through HTTP. If we implement such "over HTTP" feature in kiwix-js, it will become an issue when switching to libzim : either the feature disappears from kiwix-js (and the forks relying on it will have to keep an outdated version) or we will have to implement it in libzim (maybe with https://emscripten.org/docs/api_reference/fetch.html, but it has to be discussed and tested with their maintainers). I'm also puzzled by the fact to give this preview feature to the end-users. From what I read in #595, this won't be usable without additional pre-computed indexes (probably inside the ZIM file) : shouldn't this be discussed with libzim maintainers first? Else I don't see the point. Don't get me wrong : I understand this could be really helpful for the IPFS feature and/or for using some ZIM files from a local network. But we should not deploy some feature in kiwix-js unless we know it is sustainable in the mid/long term, and does not confuse end-users |
Pertinent, but without visibility on libkiwix emscripten, I assume this won't happen soon.
Yes, but all of this seems a problem easier to fix than the technical ones. In worse case we can make another project with another name to avoid confusion.
You are right that a preindex needs a discussion at the ZIM level (in repository
Your comment is 100% pertinent to me. |
I think the thing that interests me most about this ticket is the possibility of enabling easy access to a very large ZIM over an Intranet / LAN, without much overhead. But I've no idea how viable it is really, until the various pieces of the puzzle come together! |
Regarding the user experience, another way to handle that would be to hide this feature in the UI, and have a "secret" way to show it. This would allow to keep only one project, one source code, and one deployment. In this case, I would see that as a "playground" feature for now, that is not ready for end-users, and could be removed in the future (either because it's not viable, or because the switch to libzim breaks it) If everybody is OK with that (including @javgh and @ikreymer), I'm OK too. NB : I won't have time to work on that myself. If I find some time, I'll work on the libzim emscripten feature |
Nice! We could have our very own |
@kelson42 Is it still worth keeping this issue open? You use Kiwix Serve with library.kiwix.org to enable preview, and that seems to work fine. Also, implementing this (if possible) in Kiwix JS would mean no preview for Zimit archives currently. I'm closing but feel free to re-open if this is still wanted/needed. |
I propose to add a new feature to Kiwix JS, the capacity to ready a ZIM file online via HTTP. It should provide to the user a similar UX than with an offline/local ZIM file.
This feature would allow to:
From the user perspective the workflow could look like following: In "Configure" Tab, below the "Browser" button to load local ZIM file, we would have a text field to enter a HTTP URL pointing to a ZIM file online. This online ZIM file would be then loaded like (from a user perspective) a local file one time the user have clicked on the "Go" button beside the URL input text.
For this first implementation of a JS ZIM reader over HTTP, the page loading speed is not critical, it can be slow in a way this is still usable. If the loading takes a bit of time then a progress bar or similar should be implemented.
The key/blocker points are:
Remark: This ticket is a follower of #595
The text was updated successfully, but these errors were encountered: