nuxt-google-sheets-import
v0.1.26
Published
Schema-driven Google Sheets import module for Nuxt Content
Readme
nuxt-google-sheets-import
Schema-driven Google Sheets import and export workflows for Nuxt Content.
Documentation
- Main docs: nuxt-google-sheets-import.netlify.app
- Local docs source: docs/content
[!TIP] For setup, runtime/API details, and workflow guides, use the hosted docs as the primary reference.
Features
- 📥 Import from Google Sheets - Pull tabular data into Nuxt Content collections.
- ✅ Zod Validation - Validate and coerce row values against your schemas.
- 🧭 Guided Workflow UI - Built-in page with setup, import, and export tabs.
- 📝 Multi-format Writes - Write markdown frontmatter, JSON, or YAML.
- 🔁 Overwrite Strategies - Skip, full overwrite, or frontmatter-only overwrite.
- 📤 Export Helpers - Copy TSV for Sheets paste or download CSV.
- 🧱 Nuxt Content Aware - Resolves collection behavior for page/data collections.
Quick Start
Install and enable the module:
pnpm add nuxt-google-sheets-importexport default defineNuxtConfig({
modules: ['nuxt-google-sheets-import'],
googleSheetsImport: {
apiBase: '/api/google-sheets-import',
defaultContentDir: 'content/data',
}
})Set your Google API key:
NUXT_GOOGLE_API_KEY=your_google_sheets_api_keyThen open /google-sheets-import in your app.
Todo
- [ ] Find out why 'addTemplate' adds the example file to the module root/utils (unintended) as well as the consuming app utils folder (intended).
- [ ] Check page overrides are working as expected.
- [ ] Should @nuxt/ui be a dependency or should it just install? Pretty heavy for one page
- [ ] Check that development mode is the only mode the module runs in. If not, add safeguards to prevent unintended file writes in production.
Repository Development
Development commands:
npm install
npm run dev:prepare
npm run testPlayground:
npm run devDocs (local):
cd docs
npm install
npm run dev