4 ms·
I spent way too long trying to figure out how the hell this CSS only bar knew the current page progress. Missed step 3 on this page: add a data attribute dat
by rpicard 13y ago
I spent way too long trying to figure out how the hell this CSS only bar knew the current page progress. Missed step 3 on this page:
add a data attribute data-progrecss defining the percent complete.
- codez 13y agoSorry about that. I tried to make the page very minimal and probably sacrificed a little clarity in doing so ha.
- sfeng 13y agoIt _is_ possible http://github.hubspot.com/pace/docs/welcome http://github.hubspot.com/pace/docs/welcome
- codez 13y agoI appreciate bumping this link in a few places but I have some questions regarding it. If all you do is put a js file in and a theme file, how do you have control over what element, the progress bar is on without having to write css to do so and how do you say which requests to monitor and which ones to not? It seems like having full control isn't quite there. You could simply add an AJAX prefilter that has an update function within it before making AJAX calls and that wouldn't be many lines of code at all and means one less dependency. Just my 2 cents. Thanks for the heads up though!
- rpicard 13y agoFrom what I see that requires JS as well. It just gives you a file to update it instead of having you do it. I don't know a lot about the latest CSS features, but I don't think it's possible to have this with CSS alone.