Goodbye Wordpress, Hello Jamstack
thomasridings.com
thomasridings.com
1. Got comments and pingback with Antispam
2. Install a nice (Elastic) Search plugin with a decent search engine (name your preferred option).
3. HotSwap on the fly themes
4. Improve performance via cache plugins (there are a lot of them).
I do not run JetPack to avoid even Wordpress.com lockin. Also with PHP 8.x and code cache enabled the overall WordPress speed is very high.
So how can I get all this feature on static site generators without lockin for comments/search/moderation (just asking)?
Disqus for comments. Are pingbacks really a thing still?
Do you really hotswap themes that frequently?
You get performance out of the box with SSG that would be a lot of effort to replicate with Wordpress.
From their privacy policy:
> Disqus uses, and also engages third party ad partners and affiliates who use cookie IDs, device IDs (including mobile), hashed email addresses, IP address, ISP and browser information, demographic or interest data, content viewed and actions taken on the Service or Partner Sites, including information about the websites you’ve viewed and advertisements you’ve interacted within order to provide you with more relevant advertising targeted to your preferences and interests derived from your interaction with the Service, Partner Sites or other third party websites.
> We may sell or share your personal data with the parties set out below for the purposes set out in the table in paragraph 5 above.
Static sites have been my goto for years. Especially after Netlify launched and a free tier became available.
Now cloudflare pages offers free hosting with basically unlimited hosting for personal sites.
I couldn’t go back to wasting time managing a personal site with Wordpress.
2. Install a nice (Elastic) Search plugin with a decent search engine (name your preferred option). Same as above, for most blogs something like http://elasticlunr.com/ can get the job done really well.
3. HotSwap on the fly themes Most static site generators support this.
4. Improve performance via cache plugins (there are a lot of them). The point of static sites is you don't really need to cache data. It's already generated ahead of time. You're just serving the content.
Don't know what the best solution is. I'm currently testing Strapi CMS on the backend with a NextJS frontend which should give me hybrid between pre-rendered/ssr as well as dynamic parts while having a consistent development experience across all of them that is very familiar to developers. Definitely not as quick to launch experience as slapping together landing pages in website builders and Wordpress with pre-made templates, but I'll see how it goes.
This was a success because I really understood what I was solving for.
Each scenario will change and the solution will too.
TLDR of the article; what do you want?
That being said I do use Jamstack quite extensively, it can trivially handle huge loads due to it being mostly just static files that can be served through CDNs. This seems like it has nothing to do with Jamstack but it's still funny.
I took the site down to patch and then put it back online...If I'd only used SSG for it too.
I wrote a Jekyll Generator plugin that just makes a SQL query to the WordPress database and generates all of the sites' content a good 5 or 6 years ago. It's fairly trivial work.
With such a cache enabled Wordpress sites feel like they're static pages, while they still offer all features Wordpress offers.
Here is an example for a tutorial on how to configure that for Wordpress: https://easyengine.io/wordpress-nginx/tutorials/single-site/...
[1]: https://nginx.org/en/docs/http/ngx_http_fastcgi_module.html#...
If you don't need the features Wordpress exists for, static html is great. If you do... Wordpress actually works fairly well if you use a caching plugin.
And breathing a sigh of relief.
That's kind of my point. If you can avoid using a heavyweight tool whose features you don't need... don't use it. I highly recommend finding any alternative that would suit your needs. You will be a lot happier.
The problem is the constant unspoken assumption that heavyweight tools shouldn't be used at all.
Did think about putting a WYSIWYG editor in there but decided I didn't need one.
If you are a member at this club it's fine, but if you're just a local trying to help the club you wouldn't want to be involved in each content update all the time.
Honestly this technical solution isn’t for every scenario but I felt confident that nobody would be updating the site in WYSIWYG. Comes down to what you need. There are many tools for many jobs.
I know the personal server architecture of a bunch of docker containers reverse-proxied behind Nginx is really easy and popular but it's a lot of overhead and kills your throughput if you don't aggressively cache in the frontend.
Look at the proxy_cache_* options and you'll be able to handle the traffic with ease.
I'd be tempted to do Jamstack for it in the future and remove the Ngninx overhead all together (even if just to get rid of the ssl certificate side).
It has to be JS-free because I am a vulnerability researcher on JS/WASM-based “file-less” malware.
One thing I'm not too sure on is, can a frontend served from a CDN do SSR? It became pretty apparent over the course of developing my blog that hybrid CSR and SSR was optimal.
hello JAMstack indeed :p
Looks promising. /s
Any other sort of "stack" is going to need caching, varnish, cdn, etc.
EDIT: huh, that site claims the JAMstack is exactly a set of static pages...
"With Jamstack, the entire front end is prebuilt into highly optimized static pages and assets during a build process. This process of pre-rendering results in sites which can be served directly from a CDN, reducing the cost, complexity and risk, of dynamic servers as critical infrastructure."
People are jumping to conclusions and bashing jamstack/static without checking the source (it's not a static blog, it's ghost:node+sqlite/mysql) or reading the article (it's not about the blog, it's about https://hillcroftlacrosse.com).
We could not see the article, source, or that link.. the site was down
That's exactly the point of saying people are "jumping to conclusions".
You and the top level are doing the same but to the commenters- it's just one step further down and I feel the jokey aspect has been lost in favour of the internet's favourite response type: mild outrage over nothing
Ooh we could call it a MOON response
Comments making fun of a site praising jamstack being down are jumping to two conclusions: the site is itself is using jamstack and the praise of jamstack is for use in blogs. That's what the commenter above pointed out.
When I point out that these commenters are jumping to conclusions I am not jumping to conclusions. It is pretty clear that they are associating the use of jamstack and the site being down.
My blog isn’t Jam. It’s a ghost on T2.micro. This hit the FP and it didn’t like it.
Can’t help but think if it was Jam it wouldn’t of gone down. Then again I like the editor for ghost.
Either way, I’m not protective over Jamstack, this whole situation is ironic and funny.
I think the "Jamstack" is the single worst trend to ever happen to static site generators as both an author and a reader. The whole appeal of static sites to me is that all the files can live in one place. As a site author this minimizes the number of failure points and things I need to pay for, and as a reader it minimizes my trackable footprint online since connections only need to go to one place.
The "Jamstack" throws all of that out and encourages people to glue together as many third-party APIs as possible that they get to keep paying for forever and that cast the surveillance net ever-wider around readers. Of course nothing stops people from Missing The Point and throwing Google Analytics on a totally-static site, but "Jamstack" normalizes that behavior. This is the opposite of progress.
To be fair jamstack does not imply 3rd party APIs. A valid jamstack could all be on your own premises, just that every API is deployed independently.
Not sure how happy I'd be if I needed to stitch 50+ API services together but not every project has the same requirements and we shouldn't assume the same solution.
Tbh Wordpress nor Jamstack solve bad html.
I'd agree on a new project, jamstack makes sense here.
I did try to render the wordpress site out to html but I just didn't find it plain sailing and after a couple of hours research/testing look for a new direction.
3 free sites, followed by $3/month for each additional static site.
And it provides the same convenience of pushing to Github main (or branch of your choice) and having it automatically built and deployed.
Groundbreaking.
I wouldn't try and build a live dashboard using real-time metrics or data intensive graphs using Jamstack.
The operating assumption is that you're still going to be doing dynamic work on the site but that it will all be client side.
You'll end up rendering huge JSON blobs with your public data in your markup for your client side JavaScript to do things with. Text is cheap. The client side does all of the heavy lifting but you'll probably need things like accurate time, which you can get by rendering pages using NGINX SSI module to render server time on pages. Obviously this won't stop some users from manipulating this information maliciously so you have to be careful what you use and where.
Naming this thing was always amusing to me though -- I'd been working with clients to switch from WP to essentially JAMstack years before it was ever named anything. Then suddenly I', in the JAMstack business.
Is there any basis to believe Svelte is any more stable then any other JS framework?