{"id":13678334,"url":"https://github.com/ulivz/rspress-plugin-remote-page","last_synced_at":"2025-04-15T09:34:35.056Z","repository":{"id":203584997,"uuid":"709948538","full_name":"ulivz/rspress-plugin-remote-page","owner":"ulivz","description":"An Rspress plugin to seamlessly load remote markdown file (e.g. README.md) onto your website.","archived":false,"fork":false,"pushed_at":"2023-10-26T19:16:37.000Z","size":176,"stargazers_count":9,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-28T18:51:51.238Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/ulivz.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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":"2023-10-25T17:54:47.000Z","updated_at":"2025-03-13T05:43:55.000Z","dependencies_parsed_at":null,"dependency_job_id":"cda045e0-7e91-497f-a52c-d389694e11b4","html_url":"https://github.com/ulivz/rspress-plugin-remote-page","commit_stats":null,"previous_names":["ulivz/rspress-plugin-load-readme","ulivz/rspress-plugin-remote-page"],"tags_count":4,"template":false,"template_full_name":"ulivz/ts-lib-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ulivz%2Frspress-plugin-remote-page","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ulivz%2Frspress-plugin-remote-page/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ulivz%2Frspress-plugin-remote-page/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ulivz%2Frspress-plugin-remote-page/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ulivz","download_url":"https://codeload.github.com/ulivz/rspress-plugin-remote-page/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249043145,"owners_count":21203422,"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-08-02T13:00:52.451Z","updated_at":"2025-04-15T09:34:35.006Z","avatar_url":"https://github.com/ulivz.png","language":"TypeScript","funding_links":[],"categories":["Plugins"],"sub_categories":["Rspress Plugins"],"readme":"\u003ch1 align=\"center\"\u003erspress-plugin-remote-page\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n    An \u003ca href=\"https://rspress.dev/\"\u003eRspress\u003c/a\u003e plugin to seamlessly load remote markdown file (e.g. README.md) onto your website.\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://npmjs.com/package/rspress-plugin-remote-page\"\u003e\u003cimg src=\"https://img.shields.io/npm/v/rspress-plugin-remote-page.svg?style=flat\" alt=\"NPM version\"\u003e\u003c/a\u003e \n    \u003ca href=\"https://npmjs.com/package/rspress-plugin-remote-page\"\u003e\u003cimg src=\"https://img.shields.io/npm/dm/rspress-plugin-remote-page.svg?style=flat\" alt=\"NPM downloads\"\u003e\u003c/a\u003e \n    \u003ca href=\"https://circleci.com/gh/saojs/rspress-plugin-remote-page\"\u003e\u003cimg src=\"https://img.shields.io/circleci/project/saojs/rspress-plugin-remote-page/master.svg?style=flat\" alt=\"Build Status\"\u003e\u003c/a\u003e \n\u003c/p\u003e\n\n## Table of Contents\n\n- [Table of Contents](#table-of-contents)\n- [Install](#install)\n- [Usage](#usage)\n  - [Quickly load a `README.md` file from GitHub using a shortcut](#quickly-load-a-readmemd-file-from-github-using-a-shortcut)\n  - [Capable of loading any Markdown file from GitHub](#capable-of-loading-any-markdown-file-from-github)\n  - [Supports loading any remote Markdown files](#supports-loading-any-remote-markdown-files)\n- [Options](#options)\n  - [pages](#pages)\n    - [remotePath](#remotepath)\n    - [routePath](#routepath)\n- [TODOs](#todos)\n- [License](#license)\n\n## Install\n\n```bash\nnpm install rspress-plugin-remote-page -D\n```\n\n## Usage\n\n### Quickly load a `README.md` file from GitHub using a shortcut\n\n```ts\n// rspress.config.ts\nimport { remotePage } from 'rspress-plugin-remote-page';\nimport { defineConfig } from 'rspress/config';\n\nexport default defineConfig({\n  plugins: [remotePage({\n    pages: [\n      {\n        // This input will load README.md of https://github.com/ulivz/rspress-plugin-remote-page\n        remotePath: 'ulivz/rspress-plugin-remote-page',\n        routePath: '/readme',\n      }\n    ]\n  })],\n});\n```\n\n### Capable of loading any Markdown file from GitHub\n\n```ts\n// rspress.config.ts\nimport { remotePage } from 'rspress-plugin-remote-page';\nimport { defineConfig } from 'rspress/config';\n\nexport default defineConfig({\n  plugins: [remotePage({\n    pages: [\n      {\n        remotePath: 'https://github.com/ulivz/rspress-plugin-remote-page/blob/main/README.md',\n        routePath: '/readme',\n      }\n    ]\n  })],\n});\n```\n\n### Supports loading any remote Markdown files\n\n```ts\n// rspress.config.ts\nimport { remotePage } from 'rspress-plugin-remote-page';\nimport { defineConfig } from 'rspress/config';\n\nexport default defineConfig({\n  plugins: [remotePage({\n    pages: [\n      {\n        remotePath: 'https://path/to/your-markdown.md',\n        routePath: '/readme',\n      }\n    ]\n  })],\n});\n```\n\n## Options\n\n### pages\n\n#### remotePath\n\n- **Type**: `string`\n- **Required**: `true`\n\nSpecify the remote path, it could be:\n\n1. Github repository shortcut, e.g. `web-infra-dev/deep-dive-into-tla`;\n2. Github repository repo path, e.g. `https://github.com/web-infra-dev/deep-dive-into-tla`;\n3. Github path, e.g. `https://github.com/web-infra-dev/deep-dive-into-tla/blob/master/README-zh-CN.md`;\n4. Any remote path, e.g. `https://path/to/your-markdown.md`;\n\n#### routePath\n\n- **Type**: `string`\n- **Default**: `master`\n\nSpecify the generated route.\n\n## TODOs\n\n- Support remote `*.mdx`.\n- Enhance logging output.\n- Enhance error handling when fetching pages.\n\n## License\n\nMIT \u0026copy; [ULIVZ](https://github.com/ulivz)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fulivz%2Frspress-plugin-remote-page","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fulivz%2Frspress-plugin-remote-page","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fulivz%2Frspress-plugin-remote-page/lists"}