Cette page est affichée en anglais. Une traduction française est en cours.
ScriptsJul 1, 2026·3 min de lecture

Gridsome — Vue.js Static Site Generator with GraphQL Data Layer

Jamstack framework for Vue.js that builds fast static sites with a unified GraphQL data layer for any CMS or API.

Prêt pour agents

Installation agent prête

Cet actif peut être installé après choix du runtime, vérification du plan et exécution de la commande adaptée.

Native · 98/100Policy : autoriser
Surface agent
Tout agent MCP/CLI
Type
Skill
Installation
Single
Confiance
Confiance : Established
Point d'entrée
Gridsome
Commande d'installation directe
npx -y tokrepo@latest install 2490d288-754c-11f1-9bc6-00163e2b0d79 --target codex

À exécuter après confirmation du plan en dry-run.

Introduction

Gridsome is a Vue.js-powered static site generator that uses a GraphQL data layer to pull content from any source — CMSs, markdown files, APIs, or databases. It pre-renders pages at build time for fast loading and good SEO, while still providing a full Vue.js SPA experience in the browser.

What Gridsome Does

  • Generates static HTML pages from Vue.js components at build time
  • Provides a unified GraphQL data layer that aggregates content from multiple sources
  • Supports source plugins for WordPress, Contentful, markdown, Strapi, and more
  • Automatically code-splits pages and prefetches linked pages for instant navigation
  • Creates progressive web apps with offline support and responsive image handling

Architecture Overview

Gridsome runs a local GraphQL server during development that collects data from configured source plugins. At build time, it queries this data layer and renders each page to static HTML with embedded Vue.js for client-side hydration. The result is a set of static files deployable to any CDN or static host.

Self-Hosting & Configuration

  • Install the Gridsome CLI globally via npm or use npx for project scaffolding
  • Configure data sources in gridsome.config.js using community source plugins
  • Define page templates that query the GraphQL layer with <page-query> blocks
  • Deploy built output to Netlify, Vercel, GitHub Pages, or any static file host
  • Customize webpack configuration for advanced asset handling needs

Key Features

  • Unified GraphQL data layer aggregates content from any number of sources
  • Automatic image optimization with lazy loading and responsive srcsets
  • File-based routing with support for dynamic pages from data sources
  • Hot-reloading development server with instant GraphQL explorer
  • Plugin ecosystem for CMSs, analytics, SEO, and sitemap generation

Comparison with Similar Tools

  • Nuxt — Full-featured Vue framework with SSR and SSG; Gridsome focuses on static generation with GraphQL
  • VitePress — Vue-powered docs generator; Gridsome targets general-purpose sites with diverse data sources
  • Gatsby — React-based static site generator with GraphQL; Gridsome brings the same concept to Vue
  • Hugo — Go-based static generator; no JavaScript framework or GraphQL data layer
  • Astro — Multi-framework static builder; Gridsome is Vue-only with a tighter GraphQL integration

FAQ

Q: Is Gridsome still maintained? A: Gridsome development has slowed. For new Vue projects, consider Nuxt or VitePress. Gridsome remains usable for existing sites.

Q: What data sources can Gridsome use? A: Any source with a plugin: WordPress, Contentful, Strapi, Airtable, local markdown/YAML files, REST APIs, and more.

Q: How does Gridsome handle images? A: Gridsome automatically processes images at build time, generating responsive sizes, lazy-loading placeholders, and WebP variants.

Q: Can I deploy Gridsome to a CDN? A: Yes. The build output is plain HTML, CSS, and JS files that can be served from any static host or CDN.

Sources

Fil de discussion

Connectez-vous pour rejoindre la discussion.
Aucun commentaire pour l'instant. Soyez le premier à partager votre avis.

Actifs similaires