{"id":18408326,"url":"https://github.com/pingcap/website-docs","last_synced_at":"2025-09-20T01:23:21.418Z","repository":{"id":37097802,"uuid":"264890162","full_name":"pingcap/website-docs","owner":"pingcap","description":"The next generation of PingCAP Docs. Powered by Gatsby ⚛️.","archived":false,"fork":false,"pushed_at":"2025-09-19T06:02:09.000Z","size":8347,"stargazers_count":23,"open_issues_count":28,"forks_count":34,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-09-19T08:24:00.155Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://docs.pingcap.com/","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/pingcap.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-05-18T09:23:23.000Z","updated_at":"2025-09-19T03:15:12.000Z","dependencies_parsed_at":"2024-11-25T10:33:56.862Z","dependency_job_id":"5af29b89-68b8-4675-994b-cf069acd6bb2","html_url":"https://github.com/pingcap/website-docs","commit_stats":{"total_commits":615,"total_committers":25,"mean_commits":24.6,"dds":0.7983739837398374,"last_synced_commit":"fada2f9f8a76777b7652b043b5bffc5157292969"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/pingcap/website-docs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fwebsite-docs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fwebsite-docs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fwebsite-docs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fwebsite-docs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pingcap","download_url":"https://codeload.github.com/pingcap/website-docs/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pingcap%2Fwebsite-docs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276028317,"owners_count":25572675,"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","status":"online","status_checked_at":"2025-09-19T02:00:09.700Z","response_time":108,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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-06T03:18:28.947Z","updated_at":"2025-09-20T01:23:21.372Z","avatar_url":"https://github.com/pingcap.png","language":"TypeScript","readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"images/pingcap-icon.png\" width=\"128\" alt=\"PingCAP Logo\" /\u003e\n\u003c/p\u003e\n\u003ch1 align=\"center\"\u003ewebsite-docs\u003c/h1\u003e\n\n[Click here to view.](https://docs.pingcap.com/)\n\n## Quick Start\n\n1. Clone this repo;\n\n2. Install dependent:\n\n- Run `yarn`;\n\n3. Download docs:\n\n- Run `git submodule init`;\n- Run `git submodule update --depth 1 --remote`;\n\n### After download\n\nRun `yarn start` to develop:\n\n```sh\nyarn start\n```\n\nIn order to debug algolia searches, you need to provide two additional environment variables:\n\n- `GATSBY_ALGOLIA_APPLICATION_ID`\n- `GATSBY_ALGOLIA_API_KEY`\n\nPut them in `.env.development` to make them take effect. (Ref: \u003chttps://www.gatsbyjs.com/docs/how-to/local-development/environment-variables/\u003e)\n\n## Workflow\n\nBecause of most of our text data stored in GitHub. It's needed to apply a GitHub API token in development **when you are prompted for `rate-limiting`**.\n\nFor more details, view \u003chttps://docs.github.com/en/rest/overview/resources-in-the-rest-api#rate-limiting\u003e.\n\nYou must set the token as an env when you start some commands, defined as:\n\n```sh\nGITHUB_AUTHORIZATION_TOKEN=token\n```\n\n## The rules we followed\n\nFor better collaboration and review, we have developed a few rules to help us develop better.\n\n- [JS](#js)\n- [Styles](#styles)\n- [Be Compact](#be-compact)\n- [Necessary Test](#necessary-test)\n\n**Before you contribute, you must read the following carefully.**\n\n### JS\n\nFirst, we use [husky](https://github.com/typicode/husky) and [lint-staged](https://github.com/okonet/lint-staged) to make [prettier](https://prettier.io/) format our code automatically before commit.\n\nAnd also, because some of us use vscode to develop, we recommend to use [sort-imports](https://marketplace.visualstudio.com/items?itemName=amatiasq.sort-imports) to format all imports. (This is optional, we will not force you to use)\n\n### Styles\n\nCurrently, we use `sass` to style each pages and components.\n\nWe hope you can follow this order **(Don't care about their value)** to organize all styles:\n\n```scss\n// Position first\nposition: relative;\ntop: 0;\nbottom: 0;\nleft: 0;\nright: 0;\n// Then display\ndisplay: flex;\nflex-direction: column;\njustify-content: center;\nalign-items: center;\n// Layout\nwidth: 0;\nheight: 0;\nmargin: 0;\npadding: 0;\n// Colors\nbackground: #fff;\ncolor: #000;\n// Outside\nborder: 0;\nbox-shadow: none;\n// Finally, not often used values can be in any order\n```\n\n### Be Compact\n\n**Don't include no used deps.**\n\n**Don't let your code be too long-winded, there will be a lot of elegant writing.**\n\n### Necessary Test\n\n**Every new features must have a unit test.**\n\n## Shortcodes\n\nCurrently, you can use these shortcodes into docs:\n\n### Notifications\n\n```jsx\n\u003cNote\u003eThis is a note.\u003c/Note\u003e\n\n\u003cWarning\u003eThis is a warning.\u003c/Warning\u003e\n\n\u003cTip\u003eThis is a tip.\u003c/Tip\u003e\n\n\u003cError\u003eThis is an error.\u003c/Error\u003e\n\n\u003cImportant\u003eThis is an important message.\u003c/Important\u003e\n```\n\nEverything you need is just to write a JSX tag, put the text into it. Then we will use `mdx` to convert it to JS code.\n\n### Tab Panels\n\nUse `\u003cSimpleTab\u003e` to create a tab panel. Do not put any h1 ~ h3 headings inside the tab panel.\n\n```jsx\n\u003cSimpleTab\u003e\n  \u003cdiv label=\"LABEL_SHOW_ON_FIRST_TAB\"\u003e\n    This is the first content, which is markdown format. The content will show\n    on the corresponding panel when users switch the tabs.\n  \u003c/div\u003e\n\n  \u003cdiv label=\"LABEL_SHOW_ON_SECOND_TAB\"\u003eThis is the second content.\u003c/div\u003e\n\u003c/SimpleTab\u003e\n```\n\n## Landing page for TiDB\n\nEdit file `_index.md` in each doc repo to custom its landing page.\n\nAll columns have to be wrapped by tag `\u003cNavColumns\u003e\u003c/NavColumns\u003e`, each column has to be wrapped by tag `\u003cNavColumn\u003e\u003c/NavColumn\u003e`and column title has to be wrapped by tag `\u003cColumnTitle\u003e\u003c/ColumnTitle\u003e`. For example:\n\n```jsx\n\u003cNavColumns\u003e\n  \u003cNavColumn\u003e\n    \u003cColumnTitle\u003eColumn title\u003c/ColumnTitle\u003e- [This is nav](/fileName.md) - [This\n    is nav](/fileName.md) - [This is nav](/fileName.md) - [This is\n    nav](/fileName.md)\n  \u003c/NavColumn\u003e\n\n  \u003cNavColumn\u003e\n    \u003cColumnTitle\u003eColumn title\u003c/ColumnTitle\u003e- [This is nav](/fileName.md) - [This\n    is nav](/fileName.md) - [This is nav](/fileName.md) - [This is\n    nav](/fileName.md)\n  \u003c/NavColumn\u003e\n\u003c/NavColumns\u003e\n```\n\n## License\n\nMIT\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpingcap%2Fwebsite-docs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpingcap%2Fwebsite-docs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpingcap%2Fwebsite-docs/lists"}