Live data from Hacker News

Static Website Generators Are the Next Big Thing

smashingmagazine.com

171–180 of 187 posts

Re: Static Website Generators Are the Next Big Thing

#171

People are finally starting to realize that CMSes are horrible. They got us through a time period where the front-end developer is a scare resource, but now there's enough of them everywhere that we don't need WYSIWYG web content anymore. CMSes are eventually going to be relegated to the sole proprietor who doesn't want to learn HTML but still needs to maintain his / her own content-oriented website. My company is ha…

Couldn't disagree more. CMSs enable non-developers to publish good-looking content, which is basically what the web is. You can have a small army of 10-20 writers and 1-2 front end devs styling templates for them. It scales, and it makes sense. Content is certainly not code; it does not get compiled, it contains no logic. At best content is a property of an object with its structure defined in/as code.

Actually the moment we will finally stop treating computers as glorified typewriters and use paper and desktop metaphors, content will indeed be code. Good web content in the future, I believe, should have interactive visualisations/simulations and a multitude of possible user interactions (see for example http://worrydream.com/Tangle/). Publications like the New York Times are already implementing this, I also expect it to happen for educational content (see Khan Academy for some examples).

Re: Static Website Generators Are the Next Big Thing

#172

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.

I tried both Hugo and node.js-based Metalsmith[0] for a new version of my personal website that I launched just about a month ago. Ended up choosing Metalsmith because of its super minimalist everything is a package approach, but Hugo looked super nice too.

What I like about Metalsmith is you build you own workflow. A basic installation does nothing but copy files from the source directory to the destination directory.

I'm working on a beginner's guide to Metalsmith right now, in fact!

[0]: http://www.metalsmith.io/

Re: Static Website Generators Are the Next Big Thing

#173

Earlier quoted context omitted.

Couldn't disagree more. CMSs enable non-developers to publish good-looking content, which is basically what the web is. You can have a small army of 10-20 writers and 1-2 front end devs styling templates for them. It scales, and it makes sense. Content is certainly not code; it does not get compiled, it contains no logic. At best content is a property of an object with its structure defined in/as code.

Actually the moment we will finally stop treating computers as glorified typewriters and use paper and desktop metaphors, content will indeed be code. Good web content in the future, I believe, should have interactive visualisations/simulations and a multitude of possible user interactions (see for example http://worrydream.com/Tangle/ ). Publications like the New York Times are already implementing this, I also expe…

I wouldn't bet on it: https://graydon2.dreamwidth.org/193447.html

Re: Static Website Generators Are the Next Big Thing

#174

Earlier quoted context omitted.

Couldn't disagree more. CMSs enable non-developers to publish good-looking content, which is basically what the web is. You can have a small army of 10-20 writers and 1-2 front end devs styling templates for them. It scales, and it makes sense. Content is certainly not code; it does not get compiled, it contains no logic. At best content is a property of an object with its structure defined in/as code.

> CMSs enable non-developers to publish good-looking content, which is basically what the web is. You can have a small army of 10-20 writers and 1-2 front end devs styling templates for them. It scales, and it makes sense. Assuming that the content you're publishing is primarily writing, then yes, that makes sense. But most companies on the web are not primarily blogs or news. Hell, even the way news is going, a lot…

> But most companies on the web are not primarily blogs or news.

Sure, I agree. I've built product sites like magento.com and e-learning sites on CMSs. It's easy to knock out, say, 15 different page templates for different use cases. On bigger sites I build it out so you can customize your page by dragging sub-templates around to build a page out of it.

We've solved/attempted to solve the "don't screw up our backend" problem by exposing fields to fill out on a page. You want a headline, fill out this field and drag it to the top. You want a video background, paste the youtube link here, etc.

Re: Static Website Generators Are the Next Big Thing

#175

Earlier quoted context omitted.

Couldn't disagree more. CMSs enable non-developers to publish good-looking content, which is basically what the web is. You can have a small army of 10-20 writers and 1-2 front end devs styling templates for them. It scales, and it makes sense. Content is certainly not code; it does not get compiled, it contains no logic. At best content is a property of an object with its structure defined in/as code.

However that only works at that scale.

It works at small scale too when you download a free theme on wordpress or whatever.

Re: Static Website Generators Are the Next Big Thing

#176
post #157

Earlier quoted context omitted.

I've done lots of these kinda performance tests against all kind of dynamic sites, and higher end managed hosting services like WPEngine, etc... Once in a while someone manage to get CDN hosting just right, but it's really rare, and it's not something you can simply automate with a dynamic site (like we can for static sites with netlify). Typically the result is identical to the Smashing Magazine Site, often a lot wo…

I think CDN is over-kill/hype. If you do everything right, all you get is better latency. If your dynamic site loads slower then a static site, you are probably doing needless database round-trips, redirects, synchronized writes, or html rendering.

Yeah, caching HTML directly on a CDN basically only gives you better latency.

..Which in turn gives you better page rank. ..Which gives you more traffic.

But that's it.

..Well besides that it also gives you lower bounce-rate. ..Which means higher conversion. ..Which means higher ROI.

So there's that.

:-)

Re: Static Website Generators Are the Next Big Thing

#177
When I worked on a video search engine for UK football (soccer) clubs, we made the whole thing static.

We figured that inputs to the search was from a static range, i.e. these players, those games, that league, this type of incident (foul, goal, celebration, etc).

Then we pre-calculated all possible combinations and fired them through what we called a "cache cannon".

It was highly parallelizeable, simple to store on disk (we stored JavaScript files whose names were the form inputs), and worked extremely well.

Even for something like a search engine, unless you're doing full text search over a very wide corpus, you can look at pre-populating a cache and that cache actually being stored on your web servers and being directly addressable.

The design above, allowed that search engine to work over the weekend peak of 2 million users. That's where it shone... we just did not have to worry about the thundering herd with a pre-populated cache.

Re: Static Website Generators Are the Next Big Thing

#178
"With the maturation of browsers, many features that used to require dynamic code running on a server can be moved entirely to the client. Want comments on your website? Add Disqus, Isso or Facebook comments. Want social integration? Add Twitter or Facebook’s JavaScript widget to your website. Want real-time data updating live on your website? Add a squirt of Firebase. Want search? Add Swiftype. Want to add live chat support? Olark is there. Heck, you can even add an entire store to a static website with Snipcart.

The list goes on and on, as a whole ecosystem of purely browser-based add-ons to websites is emerging. Apart from that, modern web apps built with Ember.js, AngularJS or React are often deployed entirely as static websites and served directly from a CDN with a pure API back end that’s shared between the website’s UI and the mobile client."

--

I'm not sure I understand. It doesn't seem to me that a fully single-page, AJAX web site is truly "static". If much of the utility and content must be paged in via client-side JS calls, that too will contribute to load time and the same problems that are attributed to dynamic document generation. It may be all asynchronous and fancy, but from a UX point of view, the content isn't there until the data's retrieved. How's this any different than arguing for a grid of IFRAMEs?

After all, if your page is a minimal HTML DOM harness for a bunch of JS, can one really be said to have "loaded" the page simply in virtue of having loaded the stub HTML?

Or is this argument based mainly on either the implicit premises that (1) not all the functionality and components are used at once? or (2) that much of any given site's functionality can be off-loaded to third-party components (e.g. Disqus) which can all be loaded in parallel from different network sources?

Re: Static Website Generators Are the Next Big Thing

#179
post #20

... Next Big Thing For Minimally Dynamic Sites If your content doesn't change frequently and/or the costs of regenerating the static content is minimized for you, great. At what point do we see static sites take a fair share of the top-X-trafficked sites? Top 100? 1000? 1,000,000? This is probably great for a small corp's info site... but then the client asks for a contact form or members/admin secured area, and ther…

> At what point do we see static sites take a fair share of the top-X-trafficked sites? Top 100? 1000? 1,000,000?

Honestly, most media sites could (and probably should) be static. Think of Time, or Cracked, or CNN: a lot of content, which could be regenerated once and viewed by millions of people per regeneration. Comments could be grafted in with JavaScript (which would suit me just fine, since I don't read such sites for the comments anyway).

> This is probably great for a small corp's info site... but then the client asks for a contact form or members/admin secured area, and there we go down the rabbit hole again.

It's not an all-or-nothing thing; a web server can serve both static and dynamic content, after all.

Re: Static Website Generators Are the Next Big Thing

#180
As the primary maintainer of Pelican, a Python-based static site generator, I've given several talks on the resurgence of static site generators and in which cases they are (and are not) a good fit.

My most recent talk was two weeks ago at PyCon Japan. Following are my slides for that talk, in case that's useful for anyone who wants to get a better understanding of SSG history and advantages/disadvantages: http://justinmayer.com/talks/

Also happy to answer any questions here, of course. (^_^)

Post reply on HN