Treesaver.js - JavaScript library for creating magazine style layouts
treesaverjs.com
treesaverjs.com
edit: others who confirm are using chrome, I'm using chrome on mac so it looks like latest chrome on all platforms are affected.
In Chome 8.0.552.237 (also Win7) I got nothing on loading, but it did do the flashing thing five times on page three. Haven't been able to replicate it since on any page, though.
We'll fix it, thanks for reporting it.
Also, re: 9ec4c12949a4f3 (since I can't reply directly): I prefer continuously flowing text to paginated layouts. One of the things I like about the web is that I can choose the size of the chunks I read, rather than having a page layout defined for me. However, I do agree that an HTML-based paginated layout would be preferable to PDF for many things.
If you're curious to see how to use the framework, your best bet is to start with this tutorial we're working on: https://github.com/Treesaver/treesaver/wiki/Walkthrough
https://github.com/Treesaver/treesaver/blob/master/src/ui/ar...
A quick example I found in a google image search: http://irenevilar.com/images/uploads/elle_p1.jpg
If that could be incorporated then instant win.
Dirty laundry: Each paragraph is laid out and measured only once (at a specific column width), then the metrics are all cached. Layout is then performed by dumping paragraphs into each column and just clipping whatever overflows.
The advantage is that this process is very fast, even on a mobile device. Try resizing a window and notice how quick the re-layout is.
The downside is that certain layouts are not possible right now, such as the example you've shown.
As browsers get faster, we'd like to start doing our own line layout, which would let us do far more here (with a performance penalty, unfortunately).
Playing with the walkthrough, I'm amazed with the performance on my aging iPhone3G.
Try resizing your browser, or trying it in a mobile device.
I get flicker, slow response and no visible animation between pages in Chrome. Seeing this I expected the worst when trying it on my phone, but there it actually runs quite fine.
The issue seems to be that the transition occurs only at certain scroll points on the page, and there is zero feedback where those are - so it's scroll, scroll, scroll, and suddenly, bam transition to the next page. It doesn't help that the intervals between the pages seem to be ridiculously long.
More info here: http://news.ycombinator.com/item?id=2168659 or feel free to contact me
I'm now weighing up potential back-ends to turn this thing into a database-driven publishing framework, rather than a file-based one. Am I crazy, or has anyone else considered (or already acted upon) this?
Thanks for catching and reporting it.
"HTML5 entirely" doesn't really mean much, for example my website uses mostly HTML 4.01, but is HTML5 as well (since it's mostly backwards compatible).
eg. If you're using <div> tags then you're using HTML5.
Exactly. Build once ship on all devices.