That's it, I have begun migrating my wiki to a static site.
@neauoire Good luck! What did you use for it until now?
@neauoire you probably mentioned this already, but what are your build times like with your C site generator?
@eel I haven't taken the time to look into how to print build times in C99 yet, could you add it and make a PR to?
@neauoire in bash you can just
$ time foo
(foo being your executable)
@eel For the 300 pages of grimgrains:
0.26user 0.04system 0:00.31elapsed 98%CPU
@neauoire thanks. that's blazing fast! not even a second :)
@eel for the 80 pages of hundred rabbits.
0.26user 0.03system 0:00.16elapsed 98%CPU
@eel it's a bit different each time I run it but I haven't seen it go above .20 for this one.
@eel I think it might be faster if I use tcc with some of the debug flags off
@neauoire i wouldn't necessarily think so. as i understand it, tcc compiles faster, but gcc builds faster executables.
removing debug flags, and adding -O2 or -O3 for more compile-time optimizations could make them even faster
@eel gotcha, well, at this point I think it's plenty fast anyways~
@neauoire do you have ideas how to handle search without client-side JS? Something server side? Or just no search? I’ve been noodling on a similar move, and the best I can come up with without client-side JS or server-something is a static page with all content displayed and a prompt to use cmd+f or something.
@eli_oat no search
@neauoire big mood
@eli_oat I think I'll just make a very straightforward index, I'm not sure.
@eli_oat @dualhammers @neauoire Yeah, I saw that one as well. I recommended fuse just based on the demo seeming to work a bit better compared to the lunrjs demo. I haven't implemented either yet. I didn't really connect the dots that this could be a decent option.
Since this is client side, I'd try to reduce the amount of searchable information though. Maybe have searchable titles and tags, but don't actually search on the content of your posts.
@eli_oat @dualhammers @neauoire removing unnecessary dynamic stuff is still a good goal. Though in a wiki setting, having some amount of search is nice. Think there's reasonable ways to provide this to users and still be way below the overhead of any common js SPA framework.
Do y'all have sizing goals for your webpages? like don't exceed XXX KB?
@neauoire @eli_oat @dualhammers just doing some very rough maths. Could generate a js index object that has about 800 120-character long strings (with some overhead) for ~100kb. fuse seems to be about 4kb. And there's responsible ways to ensure to only download when needed and to have it cache.
Not sure if I'm going to implement this, but looking at the numbers it maybe possible to do it 'responsibly'. Which is not something I expected.
Merveilles is a community project aimed at the establishment of new ways of speaking, seeing and organizing information — A culture that seeks augmentation through the arts of engineering and design. A warm welcome to any like-minded people who feel these ideals resonate with them.