DEV Community

Cover image for Is the JAM stack the future of web development?

Is the JAM stack the future of web development?

RealToughCandy.io on January 03, 2021

The JAM stack consists of JavaScript, APIs, and Markup. Over the last few years, this stack has become increasingly popular with fun and new opti...
Collapse
 
nikhilmwarrier profile image
nikhilmwarrier

Note: I suck at predictions,

But JAMstack is kinda cool, and it involves lesser pressure on both the developer and servers, while keeping blazing fast page load speeds for the end-user. Hosting is pretty much free nowadays for JAMstack, what with Netlify and GH pages. Cloudflare is also coming up with a similar service.

I suppose JAMstack is the way forward for blogs and e-commerce sites, but for dynamic SPA's, a strong backend is a must.

I do think that JAMstack might overtake WordPress someday, but we're not there yet...

Anyway, what do you think, RTC?

Collapse
 
realtoughcandy profile image
RealToughCandy.io

Honestly, I was pretty skeptical of it when I first heard about it a few years back. I didn't like how it relied on so many 3rd party services to provide basic functionality (like a comment section beneath a blog post). That said, I've used both SSGs & headless CMSes in the past and freaking loved the workflow.

In the next few years I think it'll probably continue to gain popularity in the personal blog niche, especially with the tech set, but with WordPress claiming 1/3 of the web I think it'll be awhile 'til JAM goes mainstream.

Collapse
 
miriamschwab profile image
Miriam Schwab

The WordPress industry is also looking towards adopting Jamstack approaches to website development and deployment. There is a growing trend of headless WP builds, and there are also a number of tools and solutions that allow users to enjoy the benefits of WordPress, while deploying the site as Jamstack and serving fully via CDN. One example is Strattic, that allows users to use WP as usual, and then click a button to deploy as static. strattic.com (I'm the CEO).

Thread Thread
 
nikhilmwarrier profile image
nikhilmwarrier

Strattic seems cool! I will try it someday myself....

Collapse
 
nikhilmwarrier profile image
nikhilmwarrier

I too actually hated the dependence on 3rd party services, but actually it wasn't half as bad as I thought it was, though it would never be as flexible as I wanted....
Also, do using PaaS [like Firebase] for databases and auth count as JAMstack?

Collapse
 
lacikawiz profile image
Laszlo Szenes

Absolutely! It's simpler, more effective, faster, more flexible and more logical than the traditional architecture.
I actually came up with a setup that I use on my main project, which basically fits the definition of JAMStack, before I even heard about it. And probably many others did the same. So it seems to be the next logical step with the evolution of Javascript and its frameworks.
It, of course, will take a while for the technologies to mature and consolidate, hosting services to catch up, and replacements for the well established traditional hosted software (eg: WordPress) to be developed, etc.
PS: I use Svelte on the front-end, and Go or PHP (WordPress API extensions) on the back-end depending on my projects.

Collapse
 
realtoughcandy profile image
RealToughCandy.io

It's simpler, more effective, faster, more flexible and more logical than the traditional architecture.

This!

Collapse
 
adrinamin profile image
Adrin Amin Salehi

Great question! I also thought about that the last couple of days, after using Hugo for my personal site.

It eventually depends on your project requirements and what kind of content you want to display. As already mentioned, there are use cases, like social media or e-commerce, where you need to display dynamic content.
But when only displaying static content, JAMstack is the way to go. Your site loads much faster. If necessary, you can use JavaScript. Hosting your site is pretty easy and the costs for hosting are very cheap.

In the end, traditional web architecture will not disappear because there are still scenarios where you want to render your site on the server. And there are still many projects where migrating to new a architecture is very costly. But for new projects it's definitely worth considering.

Collapse
 
esportleague profile image
e-leag

Does anyone have an example of a website with dynamic content, e.g. with production product prices changing many times per hour etcc ?

Collapse
 
lbayliss profile image
Luke Bayliss

Social media is an example of a website with dynamic content and Ebay is an e-commerce example; they all have data that is changing constantly. They wouldn't work well as JAMStack as you'd have to trigger a rebuild every time someone makes a bid or creates an auction.

That's not to say you can't have the best of both worlds. Almost every application I've built in the passed two years has made use of SSR and Static.

Thread Thread
 
esportleague profile image
e-leag

And what would you choose from assistance such as gatsby but to build a mainly dynamic website?

Thread Thread
 
hijazi313 profile image
Muhammad Hamza Hijazi

SSG is not recommended where content is dynamic. you should go with SSR instead

Collapse
 
jankapunkt profile image
Jan Küster • Edited

What are the downsides of this stack?