Live data from Hacker News

Static Website Generators Are the Next Big Thing

smashingmagazine.com

81–90 of 187 posts

Re: Static Website Generators Are the Next Big Thing

#81
post #27

Most of the static site generators have serious usability problems. They are simply not usable for many users using WordPress today.

Usability problems like what?

Like George from sales making a new page or editing a call to action.

Re: Static Website Generators Are the Next Big Thing

#82
post #73
post #59

Earlier quoted context omitted.

Jake was built for news articles and prerendered all pages. News staff was able to quickly localize templates (10+ lanuages, 20+ products). That was 1999 when we didn't use Javascript or CSS, tested pages on Netscape Navigator 2 and WML (for mobile phones) became hot topic. Later Jake was misused for all kinds of other products mainly because of locali[sz]ation, permission management etc. Yeah, debugging was hard. It…

> Yahoo hired Rasmus Lerdorf and switched to PHP starting 2002. Well, that's a bit of an exaggeration. When I left Yahoo Europe in 2005, there was still Perl all over the place both in Europe and the US at least. I managed the Yahoo Europe billing system, and that was mostly Perl on the backend, for example. [small world, btw., courtesy of some minor profile-stalking: I interviewed with Ed about a position a few year…

Yahoo Europe's progress was from Perl generated static html, to Perl generated PHP.

What Rasmus' hire did was push Yahoo to allow server-side scripting languages on the web server. And that's where PHP was the blindingly obvious choice. (though, I would not be surprised if there was a bun-fight with mod_perl...)

Re: Static Website Generators Are the Next Big Thing

#83
I've only done static websites for a long while now. I created ThinCMS as a browser-based tool for building and publishing static web sites. It came about after I learned XSLT well enough to bend it to my will. I used it to build several public and private web sites, including two iterations of longwoodgardens.org (they've since moved to Drupal) and pittsburghtoday.org (where it is still used). XSLT ( and probably other static templating engines) is perfectly capable of generating complex nested navigation. The templates themselves are nested three layers so as to keep things DRY.

The PittsburghToday site is representative of the idea that a static web site is only static in the technical sense of the back-end content serving. The front-end is still dynamic since the data for the charts is being obtained from Google Docs and the Twitter feed from Twitter, etc.

I always felt like the odd man out, so I am glad to see strong interest in static web sites nowadays.

Re: Static Website Generators Are the Next Big Thing

#84
post #45

I think the simplest static site generator is a command that visits all of your routes and saves the response html into a `build/` folder. That way you can use whichever framework/stack/templating/database you're already familiar and productive with, and in the end you're just deploying a static build folder from localhost. I started doing this when it came down to hacking Jekyll to implement something that's trivial…

I would suggest keeping it simple and scripting wget instead: https://www.gnu.org/software/wget/manual/html_node/Following...

Often all that is needed is -r --no-parent

Re: Static Website Generators Are the Next Big Thing

#85
post #53

Earlier quoted context omitted.

If you're looking for a static site generator that's as easy to use as Wordpress, you could consider using Wordpress. Wordpress caching plugins can generate static HTML which then gets served to visitors directly by Apache or Nginx, without hitting PHP at all.

...and this is why we're not moving to SSGs even though this almost exact article gets posted monthly here. Its trivial to put in a cache level that generates and stores static html in from of WP, Drupal, etc. So you get both worlds; the tools that dynamic CMS's give you and the performance of a static site. I think it took me 5 minutes to install varnish on a WP server I have. Varnish delivers these pages straight f…

It's far from optimal for deployment, though, as you still occasionally depend on that WP site, and then have the hassle of handling availability etc.

I wish more CMSs would support exporting all changes directly, so that you could e.g. rsync the sites out to edge servers or a CDN and be able to use it for full failover too without suddenly having stuff expire from the caches at the most inconvenient times.

Movable Type used to be able to export everything to flat files, for example (though, I guess more out of necessity back in a world where not everyone would have a host that could/would provide PHP).

I just started redoing my blog to iterate over all the pages and wrapping my Sinatra app to fake requests to generate a full static copy that way. Lets me optionally serve it up dynamically when writing, and then generate a static copy. It's just a few hours dirty hack for now, but I'll be doing this more often - it's so nice to have most of the content completely stateless.

Re: Static Website Generators Are the Next Big Thing

#86

I've been using static site generators a lot for client work over the last two years. I started off with Jekyll, but unless you are having under 100 pages, the build process gets painfully slow (trust me, I have micro-optimised). I've since started using http://gohugo.io It's lightning fast with 1000s of pages, and quite easy to pick up.

... and easier to deploy.

Re: Static Website Generators Are the Next Big Thing

#88

I love pelican as a generator, it's great The one static generator I wish there was (unless there is one and I just haven't found it) is one that would take a tree of code files and display it kinda like github does, in a browsable file browser hierarchy with syntax highlighting when drilling down to individual files. Kind of like a precompiled static file browser, there are several dynamic file browsers around but t…

There are a few projects that will take a tree of source code and generate HTML, like LXR:

https://en.wikipedia.org/wiki/LXR_Cross_Referencer

And I think there is one for GNU GLOBAL. The point of these is usually the cross references, not necessarily making it pretty though.

Re: Static Website Generators Are the Next Big Thing

#89
post #73

Earlier quoted context omitted.

> Yahoo hired Rasmus Lerdorf and switched to PHP starting 2002. Well, that's a bit of an exaggeration. When I left Yahoo Europe in 2005, there was still Perl all over the place both in Europe and the US at least. I managed the Yahoo Europe billing system, and that was mostly Perl on the backend, for example. [small world, btw., courtesy of some minor profile-stalking: I interviewed with Ed about a position a few year…

Yahoo Europe's progress was from Perl generated static html, to Perl generated PHP. What Rasmus' hire did was push Yahoo to allow server-side scripting languages on the web server. And that's where PHP was the blindingly obvious choice. (though, I would not be surprised if there was a bun-fight with mod_perl...)

In the teams I worked with, there was thankfully no Perl-generated anything (but I know my boss had to deal with that with a couple of the other teams reporting in to him). We had plenty of Perl on the backend, though, and the US billing team constantly breathing down our neck to do their OneRewriteToBindThemAll in PHP (they had been working on that for a while when I joined in 2003, and were still working on it when I left beginning of 2006; it was a laudable goal - there were something like 8 billing systems worldwide at that point - but it took them a lot of time to figure out how to unify all the international requirements).

The funny thing was that on the instances I heard Rasmus talk, he complained we were taking it too far - he wanted simple PHP templates, not the kind of large PHP applications the US billing team and others were doing. He sounded quite exasperated about it last time I was at one of his talks.

Re: Static Website Generators Are the Next Big Thing

#90
FYI: I've put together a showcase of the world's greatest static sites [1] (using the Jekyll machinery). Examples include: Bootstrap, Google Polymer, Facebook React, Open Data Handbook v2, PHP: The Right Way and many more. Cheers. [1]: http://planetjekyll.github.io/showcase
Post reply on HN