Building a Single Page Static Site with Hugo: Not as easy as it seems
I recently launched www.seattledatingpics.com for my photography work. It is a simple static landing page that pitches my online dating focused photography in Seattle. It seemed like overkill to launch a new wordpress site just for a single page so I decided to use Hugo (https://gohugo.io) as a static site generator. Hugo is written in Go and offers a way to create static sites with markdown and themes. Unfortunately, Hugo’s documentation for single page static sites is difficult to find. The solution is that you need to find a theme which supports a single page static site, and then you create a _index.md file which acts as your home page. Here is my config.toml for a single page static hugo site.
baseURL = "http://www.seattledatingpics.com"
languageCode = "en-us"
title = "Seattle Dating Pics"
theme = "ananke"
DefaultContentLanguage = "en"
SectionPagesMenu = "main"
enableRobotsTXT = true
background_color_class = "bg-dark-blue"
_index.md for a single page static site
---
title: "Seattle Dating Pics"
date: 2018-12-30T18:22:27-08:00
draft: false
---
Online Dating is difficult and the right pictures make all the difference. I can help you capture your better side and help you meet people online.
I started seattledatingpics because I had trouble getting good pictures for online dating apps. Online dating should be fun and having good pictures helps.
### Options ###
__Take a Turn__: You and I will take turns taking pictures of each other with my equipment. We will get shots of the same positions and poses. This is free as long as you take a turn with the camera!
__Hire me__: You hire me to do a photo shoot of you. We will move around Seattle filling in your profile. I have rooftop deck and gym access. We can hit great spots that you like or go to my favorite places in the city.
Send me an email at __nick@sledgeworx.io__ with seattledatingpics in the subject line and we will setup a photo shoot!
Remember to turn the draft parameter to false before you build for production. I was banging my head against the wall trying to figure out why my website worked locally, but not on S3.