6 ms·
SSGs versus Wordpress is surprisingly still a battle… I’m genuinely shocked at the number of sites on the Net that use Wordpress, dynamically assembling markup
by xp84 7mo ago
SSGs versus Wordpress is surprisingly still a battle… I’m genuinely shocked at the number of sites on the Net that use Wordpress, dynamically assembling markup with PHP for every page view, risking constant hacking and stuff, when they have a total of like 7 or 100 pages, which could all be pre-rendered to HTML files in roughly 8 seconds on even a junky laptop or X-small ec2 instance. It really is okay.
For those who post regular updates on those sites, there are great and cheap WP plugins that export the whole site as static to something like FTP or S3, so you can just firewall the actual WP behind an IP restriction and host the actual public-facing site from S3/whatever.
- mooreds 7mo agoWordpress has: * the ability to schedule posts * a ton of plugins * a lot of people who know how to use it * a reasonable WYSIWYG interface As far as I know, most SSGs fall down on one or more of those dimensions.
- joemaller1 7mo ago3rd bullet. I do a ton of WordPress at work. Clients asked for it because they know how to use it.
- corny 7mo ago* live preview
- wltr 7mo agoI can live preview my website from my local server / computer / laptop, while writing content from basically anything. Even a cheap and underpowered writing deck with 400 MHz CPU. The options are limitless.
- 9dev 7mo agoYou're absolutely underestimating the complexity of proper live preview of changes. This is essentially "hot reload" mode, but on the public internet, because it has to run on a public domain. Getting that right is a challenge, and if you don't know why, you haven't attempted to solve it yet.
- Lammy 7mo agoWhy would I want my WIP site to be on the public internet? This has been built into Jekyll for years. Probably other SSGs too but I don't know/use them. jekyll serve --watch --incremental
- 9dev 7mo agoBecause you're thinking in the context of a solo developer working on their site locally. You don't need a CMS. People that want to collaboratively work on a website, some of which may lack technical skills, need a way of previewing their edits that doesn't involve running shell commands.
- Lammy 7mo agoYou're conflating the two unnecessarily. There's no reason Jekyll's server has to run on the editor's local machine. See my other comment about jekyll-admin which can be used collaboratively: https://news.ycombinator.com/item?id=47737324 https://news.ycombinator.com/item?id=47737324 I don't see much of a difference between `jekyll serve` and the e.g. `service nginx start && service php-fpm start && service mariadb start` that would be needed to run WordPress. In fact I don't run my WIP Jekyll site on the same machine that I edit from. Mine is available only on my personal mesh VPN, but it could easily be available publicly if I wanted it to be.
- wltr 7mo agoI would appreciate getting into more details. As it sounds like a made-up problem to me. Perhaps you don’t understand how simple it is to have a static website as compared to a dynamic one. Especially to some simple project.
- evanelias 7mo agoIronically, one of the original major reasons WordPress became popular was its dynamic nature. It dethroned Movable Type, which was an extremely powerful and extensible static site generator. It's wild to me that this post's timeline makes no mention whatsoever of Movable Type, and at one point it links to another author's post titled "A Complete History of Static: The Beginning to WordPress Headless" which also makes no mention whatsoever of Movable Type. Now I feel old :/
- JavierFlores09 7mo agoTo my surprise, Movable Type is still being developed even today. Wonder if there's some companies still using it out inertia. I know many moved off of it back when they restricted their free tier
- evanelias 7mo agoI haven't kept up with it in recent years, but I know it remained popular in Japan for many years longer than elsewhere. AFAIK since 2011 it has been developed by a Japanese company, who acquired Six Apart's former subsidiary there, as well as the brand name. It's also interesting that so many people in this thread are saying "What I really need is a SSG that also works as a CMS with a GUI" -- that's literally what Movable Type excelled at. Especially versions 4 and 5, which had a FOSS edition. A number of major US media sites were powered by it for years. However because it was written in Perl, that became a huge negative point as Perl fell out of use in the industry.
- faangguyindia 7mo agoI recently moved all my website from WordPress. In last few year couple of them had got hacked via plugin exploits as well. I had to use "security" plugins after that i didn't have any issue but still... I crawled own website and downloaded each, and converted to markdown then used static site generator (custom in javascript) runs on cloudflare pages for free with no downtimes or "fee". if you want to see result: https://aretecodex.pages.dev/guides/recomposition https://aretecodex.pages.dev/guides/recomposition Couple of problems: To edit content i've to use "image paste" plugin and configure its base directory, image path in project setting in .vscode I lost the comment/upvote feature. I lost "search"
- busterarm 7mo agoThe WordPress hacking/plugin security issue has been a solved problem for well over 10 years now if you're even basically competent. Especially if you're using something like WP Engine or Pantheon for hosting.
- nchmy 7mo agowhat is unique about those hosts with regards to plugin security?
- xp84 7mo agoWP Engine etc. cost a fortune - tens of thousands per year when you get a lot of traffic - for something that could be served statically for pennies.
- busterarm 7mo agoRead my other comment. You can very easily use WordPress as just the CMS and still serve static content built from it. So $30/mo for a secure, globally accessible backend for all of your content editors and pennies to serve it.
- xp84 6mo agoThat's exactly what I advocate for as well. Static site export plugin for WP, and firewall WP behind an IP restriction. When Marketing updates the site every 3 weeks they can go click the big "Export" button to "publish it to the main site."
- CJefferson 7mo agoTo me, the thing wordpress installs offer is the GUI. I help a few people with wordpress installs, and I've ended up setting up a private wordpress install, and then I run a script which mirrors the website statically -- this is moderately hacky, and I'm sure could be done better, but as long as I hide the private wordpress install, it means I don't need to worry about keeping it up to date. I haven't found a static generator which has as nice a WYSIWYG interface as wordpress.
- yallpendantools 7mo agoIs there a tenable workflow for the marketing department to use a SSG over Wordpress? - WYSIWYG editor is table stakes. The lovely folks at marketing once thought I was hacking when I `ps -eaf`-ed in an unresponsive Macbook. - They "put" images in their post. They don't "upload the image and position it with CSS". - It's the marketing department so they have to have all sorts of bells and whistles. At the very least tracking, at most some obscure integration plug-in that as an engineer I have no kind words for. Social integrations and "You may also like..." sections also come to mind. > cheap WP plugins that export the whole site as static to something like FTP or S3, so you can just firewall the actual WP behind an IP restriction and host the actual public-facing site from S3/whatever. Not that I have extensive WP experience but unless you can name me an actual plugin that has good street cred for being used in the wild wild west, I'm gonna say this is not as easy as you make it sound. For one you just described a very rudimentary data pipeline which someone has to support and maintain even infrequently. Also, speaking from experience, plugins don't always play nice with other plugins. I once tried to export my very basic personal site out of WP to find the footnotes all messed up (I don't know now but back then I handled footnotes with a plugin).
- hobofan 7mo agoI think that's exactly the point where the article falls flat. There is potentially a big oppurtunity in building a SSG + CMS solution despite the past failed attempts. Every few years I go looking for something that's not Wordpress that you could hand to a marketing department, but there is no viable alternative (that's not Drupal).
- ymolodtsov 7mo agoThere's a number of headless CMS solutions for commercial websites. Hosted, multi-user, paid. It's just a different category.
- pjmlp 7mo agoThat is where headless CMS with Vercel and Netlify partnerships, using Next.js SSG capabilities come into play, regardless how much folks hate them.
- nchmy 7mo agohave you ever heard of caching? because it can do the exact same thing as what you just described, yet WP can also be dynamic, have visual page and post builders, etc...
- teekert 7mo agoI started my client's site on Hugo, withing 2 days I was editing something for them every 30 mins (slight exaggeration). They wanted something they could edit, they don't do Markdown, they don't manually write URLs they want to drag images into their posts and pages. So bye bye Hugo.
- ozim 7mo agoNormal people refuse to learn markdown - they want RTF editor. I could understand someone might refuse learning LaTex but markdown is so simple. RTF editing sucks badly if you have to include it in your project. No one wants to specifically pay for implementing it but they also expect it to be there.
- notpushkin 7mo ago> RTF editor Is that what they call WYSIWYG? :eyes:
- ozim 7mo agoRTF editor may be part of WYSIWYG solution but it also might be used to edit text that on publication will be looking entirely differently or will be used in various places.
- notpushkin 7mo agoOhh, I think I get it now – is this about literally using RTF as an intermediate format? I really don’t think I’ve heard about it being used in the context of static sites, but I see how it might make sense as a way of storing, well, rich text. Pandoc is your best friend in such cases: https://pandoc.org/ https://pandoc.org/
- trinix912 7mo agoNowadays you can just use one of those WYSIWYG markdown editors that come with a toolbar (incl. buttons for inserting images) and hide the formatting syntax by default.
- nabeards 7mo agoFor those looking for an SSG with WYSIWYG, please take a look at Publii. I have no affiliation other than being a user, but I wish more people were aware of it.
- Lammy 7mo agoI am a fan of jekyll-admin: https://github.com/jekyll/jekyll-admin/ https://github.com/jekyll/jekyll-admin/ Its project page doesn't seem to have a screenshot of the post/page editor, but its editor is simplemde so one can just look at it directly: https://simplemde.com/ https://simplemde.com/
- skyberrys 7mo agoSwitching from word press to static site generator caused disruption to my autoflow habit of posting. WordPress (I didn't have to maintain) had a gui I didn't have to think to use. I still made the switch though.
- nedt 7mo agoWordpress can be part of a SSG setup - it's not versus.
- azangru 7mo ago> I’m genuinely shocked at the number of sites on the Net that use Wordpress, dynamically assembling markup with PHP for every page view, What puzzles me about static sites (and I do build them) is how everything gets to be regenerated, even though you update only one file. Now, imagine that your writing patten is small notes, like on twitter, mastodon, or bluesky. Over time, with this pattern, you will end up with thousands of notes. Is each one deserving of a page? Ideally, yes; because they should be linkable. Does it make sense to regenerate thousands of pages every time you add a note? Dunno. Then, consider all the aggregation pages. For example, a paginated list of all my notes. Or a paginated list of notes distributed by different categories / tags. How many more pages does this create? And the static assets that all get to be copied from source to output directory at every build. And of course, comments. Static sites don't have comments. I don't know. I think someone who invested into building their own site engines, like Jeremy Keith (https://adactio.com/ https://adactio.com/) have it the best.