-
Notifications
You must be signed in to change notification settings - Fork 25
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
Lazy load #9
Comments
Hi, Jan |
I think this is very required feature for everyone ^_^ GOOD LUCK GUYS |
I will have some great news for you in the next days... ;) |
Is there an update on the lazy loading feature of external HTML files? I'm currently working on a very large slide set (over 300 slides) and it gets so extremly slow and I hope that I can speed up loading by your great feature! |
Hi, |
In the lazy-load branch you can just try out the updated example which has a working implementation of lazy load in it. |
Thanks, this works great! My slides are loading so much faster now. However, there are still two issues in my case, the plugin only works with Firefox, not with Chrome. Is this normal? Besides, the presentable plugin can no longer create a table of contents, which makes sense if the slides are loaded lazily, I guess. Unfortunately, the menu plugin is also not working. Do you have any suggestions how to create a table of contents? |
Thanks for your reply! Surely it is not possible to create the "out of the box" TOC for reveal.js due to the full content is not being loaded during initialization process. I will think about that and try to find a solution... |
The console tells me: Failed to load EXTERNAL_FILE Cross origin requests are only supported for protocol schemes: http, data, chrome, chrome-extension, https. Could it be that it doesn't work because it is stored locally? If this is the case than everything should be fine after uploading to my server. I will try that out. |
Does the error also show up in the example project? Or only in your specific project? |
It shows up in both projects. And as I conjested, the site is working with Google Chrome if it is accessed to via a server. |
Others problems with lazy loading:
Do you know any workaround for these problems? |
I'm enjoying your plugin for my large set of slides. However, unfortunately, the plugin is not working with the Google Chrome browser when stored locally. This was no problem so far since I've used Firefox for checking local files and Google Chrome when uploaded to the server. Now, I'm currently working on porting my slide set to an Android app. As far as I can see, Androids Webview is based on Chrome and since the files are stored locally in the app (this is actually the feature that I want) the plugin is no longer working. Do you have any suggestions how to run the plugin with Google Chrome on local files? |
Sorry for my late reply. After lots of research I might have an acceptable solution for you. Referencing to this post on stack overflow, unlike to other browsers Google Chrome seems to have some implemented security features, which were disabling AJAX requests via file:// protocol. There does not seem an in-code solution for this problem. To use reveal_external without a server connection in Google Chrome, this might be a nice browser extension you will like! After installation, you can specify the root folder of your reveal.js presentation, and it will automatically start a web server on your machine. The displayed link will show you the working presentation running on your local machine. I tested this extension in combination with reveal.js and reveal_external successfully. To get the reveal_external presentation to work in an android app, you might find a solution in this stack overflow post. According to this, you will need to change some settings of the web view you already implemented in your app. I point out that I could not test this scenario due to a lack of equipment. I hope I could help you so far. |
Concerning your post of 13 Jun:
Sure, that has the same reason as described earlier. But as this feature does not seem to have to work during presentation (usually the slides were printed before or after holding a presentation), you can simply disable the reveal_external plugin for the printing process.
This is also true as references in reveal.js are simply said nothing else than HTML links. When the browser cannot find the target referenced in the link tag, nothing will happen at all, because in fact the target is not being loaded at the time the reference link is clicked. The slide, which is specified as asynchronous, does not appear in the DOM at all, so there is no possibility for reveal.js to resolve the correct link target. I might think about implementing a mechanism handling this reference-error in future. |
Is it possible to use this plugin in order to lazy load pieces of the presentation, only when needed? If not, can you recommend a different plugin for that. Thanks!
The text was updated successfully, but these errors were encountered: