{"id":15019373,"url":"https://github.com/wflixu/nblog","last_synced_at":"2026-01-02T12:39:41.534Z","repository":{"id":255148747,"uuid":"848685859","full_name":"wflixu/nblog","owner":"wflixu","description":"Notion database as CMS for  blog ","archived":false,"fork":false,"pushed_at":"2025-03-16T12:56:36.000Z","size":970,"stargazers_count":6,"open_issues_count":1,"forks_count":3,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-23T21:45:50.783Z","etag":null,"topics":["blog","cms","notion","vitepress","vitepress-blog"],"latest_commit_sha":null,"homepage":"http://blog.wflixu.cn/","language":"Vue","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/wflixu.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-28T08:07:03.000Z","updated_at":"2025-03-11T06:15:04.000Z","dependencies_parsed_at":null,"dependency_job_id":"f16bf27f-a816-4104-80cd-b4466c02fb21","html_url":"https://github.com/wflixu/nblog","commit_stats":null,"previous_names":["wflixu/nblog"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wflixu%2Fnblog","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wflixu%2Fnblog/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wflixu%2Fnblog/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wflixu%2Fnblog/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wflixu","download_url":"https://codeload.github.com/wflixu/nblog/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248103803,"owners_count":21048238,"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":["blog","cms","notion","vitepress","vitepress-blog"],"created_at":"2024-09-24T19:53:23.864Z","updated_at":"2026-01-02T12:39:41.528Z","avatar_url":"https://github.com/wflixu.png","language":"Vue","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Blog powered by VitePress and Notion\n![](./public/favicon.svg)\n\n[Live Demo](http://blog.wflixu.cn)\n\n## 动机\n\n之前用过很多的 blog 程序，比如 hexo,astro，nextjs 等，这些程序发布完成了，下次写blog就忘记了，一般在项目中写 markdown 文件，体验不好，自己以后总结和查看都不方便，一直想找一个编辑体验如 Notion Obsidian 的笔记软件，展示可以自定义样式，现在用 Vitepress + Notion ，终于实现了这个功能，Notion 作为 markdown 编辑器 和 blog CMS，Vitepress 作为博客渲染器，完美结合。\n\n\n## 使用方法\n\n\n\n### 1. 安装依赖\n\n```bash\npnpm install\n# 或\nnpm install\n```\n\n### 2. 配置环境变量\n\n复制 `.env.example` 文件为 `.env`，并填入你的 Notion API 配置：\n\n```bash\ncp .env.example .env\n```\n\n编辑 `.env` 文件：\n\n```env\nNOTION_TOKEN=ntn_xxxxxxxxxxxx\nDATABASE_ID=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx\nAPI_HOST=https://api.notion.com/v1\n```\n\n#### 获取 Notion API Token\n\n1. 访问 [Notion Developers](https://www.notion.so/my-integrations)\n2. 点击 \"New integration\" 创建一个新的集成\n3. 复制 \"Internal Integration Token\"（格式：`ntn_...`）\n4. 将其填入 `.env` 文件的 `NOTION_TOKEN`\n\n#### 获取 Database ID\n\n1. 在 Notion 中打开你的博客数据库\n2. 从 URL 中复制 Database ID（32位字符）\n3. 将其填入 `.env` 文件的 `DATABASE_ID`\n\n#### ⚠️ 注意事项\n\n- **永远不要**将 `.env` 文件提交到 Git\n- `.env` 文件已经在 `.gitignore` 中，不会被提交\n- 只提交 `.env.example` 作为模板\n\n### 3. 启动开发服务器\n\n```bash\npnpm run dev\n# 或\nnpm run dev\n```\n\n### 4. 构建生产版本\n\n```bash\npnpm run build\n# 或\nnpm run build\n```\n\n\n## 感谢\n\n这个仓库是 根据 [airene vitepress-blog-pure](https://github.com/airene/vitepress-blog-pure) 改造的，原来是用本地md 文档管理博客，因为 vitpress 有SSG 的功能，改造成用Notion作为编辑端和管理端，vitepress 作为博客的渲染器，这样可以更好的管理博客文章，写博文是编辑体验更好。\n\n## 开源协议\n\n本项目采用 [MIT License](LICENSE) 开源协议。\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwflixu%2Fnblog","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwflixu%2Fnblog","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwflixu%2Fnblog/lists"}