Idea: ExDoc Faster page handling

24 views
Skip to first unread message

OvermindDL1

unread,
Jan 17, 2018, 10:19:41 AM1/17/18
to elixir-lang-core
_Purely playing with an idea for discussion, not an actual feature request, more curious as to how the idea of enhancing ExDoc with javascript while still being fully functional without javascript is thought about._

Right now the generated ExDocs generate static HTML that works sans javascript and all (although could use some cleaning in some cases via some CSS fixing, but that's another issue), however loading between documents still takes over a second, this could be solved via something like the Unpoly.js library that can decorate links to allow, for example, preloading when the cursor moves over a local link so swapping is instant (with optional transition, but eh there).  The useful bit of that is it makes the page faster when javascript is enabled, but it continues to function perfectly even if javascript remains entirely disabled.  It would require including the single unpoly.js file and including it on the page and decorating the relevant DOM elements with tags to indicate which should be enhanced.  Unpoly also has other features that could be used over time as well.  The reason I like this style is it allows the page to be enhanced with javascript without removing the ability to, for example, viewing the site in elinks (as I often do, and the site does not look 'great' in elinks as it is, some more DOM and CSS cleanup could fix that as well though, but again, that's a different issue).

* Unpoly.js:  https://unpoly.com

Reply all
Reply to author
Forward
0 new messages