Simplified version of our website, made with Nuxt, Tailwind CSS and Nuxt Content module. Deployed to Github Pages.
For content management purposes, we're using a file-based CMS - Nuxt Content. You can learn more about it in its documentation.
All website contents are stored within content directory. To add a new blog post, you need to create a markdown file in content/blog, that starts with following Front-Matter block:
---
title: "Blog post title"
date: 2024-02-23T16:09:04.753Z
description: "Example post description/excerpt"
image:
src: /img/blog/thumbnail-filename.png
alt: Alternative text describing the thumbnail, uses post title if empty
categories:
- articles
authors:
- name: Author Name
title: name
---
Markdown content starts here.
While most of the fields should be self-explanatory, let's focus on the categories and authors keys:
- In categories we need to put an array of post categories, using names of YAML files stored in
content/blog/categories, e.g.articlesortutorials. - Authors is an array of objects, each of which must contain two keys:
name, where we put the full name displayed on the page, andtitle, where we have to add a name of a YAML file stored incontent/_team, containing author's details like avatar, description etc.
Make sure to install dependencies:
# npm
npm install
# pnpm
pnpm install
# yarn
yarn install
# bun
bun installStart the development server on http://localhost:3000:
# npm
npm run dev
# pnpm
pnpm dev
# yarn
yarn dev
# bun
bun run dev