{"id":21058262,"url":"https://github.com/bluefrog130/vite-plugin-sheets","last_synced_at":"2025-03-14T00:28:34.109Z","repository":{"id":57393193,"uuid":"438068510","full_name":"BlueFrog130/vite-plugin-sheets","owner":"BlueFrog130","description":null,"archived":false,"fork":false,"pushed_at":"2021-12-20T02:05:57.000Z","size":23,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-20T12:47:35.224Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BlueFrog130.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-12-14T00:38:47.000Z","updated_at":"2021-12-20T02:06:00.000Z","dependencies_parsed_at":"2022-09-15T02:40:55.602Z","dependency_job_id":null,"html_url":"https://github.com/BlueFrog130/vite-plugin-sheets","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlueFrog130%2Fvite-plugin-sheets","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlueFrog130%2Fvite-plugin-sheets/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlueFrog130%2Fvite-plugin-sheets/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BlueFrog130%2Fvite-plugin-sheets/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BlueFrog130","download_url":"https://codeload.github.com/BlueFrog130/vite-plugin-sheets/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243502935,"owners_count":20301149,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-19T17:07:18.227Z","updated_at":"2025-03-14T00:28:34.082Z","avatar_url":"https://github.com/BlueFrog130.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# vite-plugin-sheets\n\nRelaces `%sheets.\u003csheet\u003e.\u003cslot\u003e%` with content.\n\nUseful when using Google Sheets as CMS. Spreadsheet must be shared with the service account.\n\nCheck out the [Sheets API](https://developers.google.com/sheets/api/) to get started. You must have a Google Cloud Project with the \"Sheets API\" enabled.\n\n|:warning: Warning |\n|:------------------|\n|Only loads sheets data once per build, this is to save API calls. Therefore changes made to the sheets during development will not be displayed until restarting the dev server.|\n\n#### Required Options\n\n- `creds`: Path to [service account credentials](https://console.cloud.google.com/iam-admin/serviceaccounts)\n- `spreadsheetId`: Defines what Spreadsheet ID to point to\n\n#### Other Options\n\n- `slotColumn`: Defaults to `0`. Which column to look use as slots.\n- `contentColumn`: Defaults to `1`. Same as `slotColumn` but for the content.\n- `ignore`: Defaults to `true`. Weather or not to treat row `1` as a header column.\n\n\n### Sample Config\n\n```js\nexport default {\n  plugins: [\n    sheets({\n      creds: \"creds.json\",\n      spreadsheetId: process.env.SPREADSHEET_ID\n    })\n  ]\n}\n```\n\n### Sample Sheet Setup\n\n#### \"Home\" Sheet\n\n|Slot|Content|\n|-|-|\n|title|Awesome Title|\n|content|Cool content|\n\n#### \"About\" Sheet\n\n|Slot|Content|\n|-|-|\n|title|About Us|\n|something|Other stuff|\n\nThe header row gets ignored by default.\n- `title` in the \"Home\" sheet would be mapped to `%sheets.home.title%`\n- `content` in the \"Home\" sheet would be mapped to `%sheets.home.content%`\n- `title` in the \"About\" sheet would be mapped to `%sheets.about.title%`\n- `something` in the \"About\" sheet would be mapped to `%sheets.about.something%`","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbluefrog130%2Fvite-plugin-sheets","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbluefrog130%2Fvite-plugin-sheets","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbluefrog130%2Fvite-plugin-sheets/lists"}