2 Building a basic Jamstack site

 

This chapter covers

  • Using the Jamstack to build a simple site
  • How to install and make use of Eleventy
  • Creating a coffee shop website using Eleventy

The first site we’re going to build in the Jamstack will be what has previously been referred to as a brochureware website. In the past, this was used to describe websites that were nothing more than digital versions of a marketing brochure. While the web is an incredibly powerful platform and enables powerful collaboration, sometimes simple is all you need. There are multiple examples of where a one- or two-page site is more than satisfactory:

  • A restaurant website that just displays opening hours, the address, and a menu (but not in a PDF please!)
  • A temporary website for a service that is coming soon, perhaps with a simple form for people to sign up to be notified on release
  • A landing page for a mobile app, with only links to the respective app stores

Each of these examples could easily be handled by a website with one to two pages. In fact, a static site generator may even seem like overkill for such a small project. But as many developers know, projects tend to grow over time. By starting off with a static site generator, you’ll be much better prepared to adapt the website and add additional pages and features over time. For our first static site generator, we will use the incredibly flexible Eleventy.

2.1 Working with Eleventy

 

2.1.1 Creating your first Eleventy site

 
 
 

2.1.2 Working with template languages

 
 
 

2.1.3 Adding layouts and includes

 
 

2.1.4 Using collections in your Eleventy site

 
 
 

2.1.5 Working with data

 

2.2 Let’s build Camden Grounds

 
 

2.3 Going further with Eleventy

 
 
 
 

Summary

 
 
 
 
sitemap

Unable to load book!

The book could not be loaded.

(try again in a couple of minutes)

manning.com homepage
test yourself with a liveTest