What's Included

a drawn web page with callouts to different parts

Features

  1. SSG with Nuxt v3 front-end in NuxtContent Markdown
  2. NuxtContent v3 Collection Implementation
  3. Custom Controls - NuxtContent and Vue
  4. Shared functions
  5. Tailwind CSS Prose, Grid, and DarkMode
  6. Git Deployment and Cookie-free Web Analytics

Definitions

  • SSR Server Side Rendering - Server runs the JavaScript, fetches data, modifies the HTML document before sending to the browser to render.
  • CSR Client Side Rendering - Server sends the HTML scaffold document and the JavaScript to the browser. The browser runs the JavaScript, fetches data, and renders the updated HTML document.
  • Universal Render - (aka dynamic rendering, or hydrated rendering) is both SSR and CSR.
  • SSG Static Site Generation - Generate the site and upload the pre-rendered site to a static web hosting service
  • SPA Web Apps/Single Page Apps - single page app like Facebook, Twitter/X
  • Hydration is making a static page interactive in the browser. You 'hydrate' a static page, when the client JavaScript is run and document re-rendered.

Folders

FolderDescription
/root folder
/appNuxt.js client folder (v4 compatibility)
/serverNuxt.js server folder
/app/pagesNuxt.js client pages root folder
/contentNuxtContent Markdown pages folder
/app/layoutsNuxt.js layouts folder
/app/componentsVue.js custom components folder
/app/components/contentNuxtContent components folder
/publicImages and files served live
/shared/utilsJavaScript shared (client&server)

Files

Options and Script FilesDescription
.gitignoreGit ignore options file
nuxt.config.tsNuxt.js options file
content.config.tsNuxtContent options file
tailwind.config.jsTailwind CSS options
package.jsonNPM package dependency file
buildspec.ymlAWS CodeBuild script
tsconfig.jsonTypescript options file (not used)
LICENSE.txtLicense file for repo
README.mdREADME file for git repo
Site FilesDescription
error.vueVue page for ERRORS
/app/app.vueVue.js application entry
/app/pages/*.vueNuxt.js pages
/content/*.mdNuxtContent Content pages
/content/license.mdLicense page for website
/app/layouts/*.vueNuxt.js layouts components
/app/components/*.vueVue.js custom components
/app/components/contentNuxtContent custom components
/app/router.options.jsVue.js router options file
/shared/utils/*.[js,ts]JavaScript shared (client&server)

Content Pages

at /content

PageFileDescription/Purpose
Home/index.mdshow code/pre blocks with styling
About/about.mdno frills content page
Articles Home/articles/index.mdlonger form content
Articles/articles/*.mda set of articles
Git Repogitprojects.mdshows external API usage
Blog Homeblog/index.mdblog list
Blog Postsblog/202x/*.mda set of posts

NuxtContent Controls

at /app/components/content

Custom Control FileDescription/Purpose
CollectionList.vueparent list of posts, used in both articles and blog
FigureCaption.vueA centered full-width block image with a caption
GitList.vueretrieves a list of GitHub repos
MonkInset.vueFloats an image or text with content flowing around it.
TocLinks.vueCreates a table of contents for page.

Vue Controls

at /app/components

Custom Control FileDescription/Purpose
ColorModeSelector.vuecontrol to toggle dark modes
Footer.vuebottom menu
TopMenu.vuetop menu

Dependencies

from /package.json

  "dependencies": {
    "@nuxt/content": "^3.1.1",
    "@stefanobartoletti/nuxt-social-share": "^1.2.0",
    "nuxt": "^3.6.0",
    "nuxt-cloudflare-analytics": "^1.0.8",
    "remark-unwrap-images": "^4.0.0",
    "vue": "^3.4.21",
    "vue-router": "^4.3.0"
  },
  "devDependencies": {
    "@nuxt/devtools": "^0.0.1",
    "@nuxtjs/color-mode": "^3.3.3",
    "@nuxtjs/tailwindcss": "^6.11.4",
    "@tailwindcss/typography": "^0.5.13"
  }
}

Essentially, the dependencies are:

  1. Nuxt.js v3
  2. Nuxt Content v3
  3. Nuxt Devtools - (for debugging)
  4. Nuxt Color Mode - (for dark modes)
  5. Nuxt Tailwind CSS - style
  6. Tailwind Prose and Typography - Content Readability
  7. Nuxt Social Share buttons
  8. Nuxt CloudFlare Analytics - Cookie-free CloudFlare Analytics for static site