Skip to content

Commit

Permalink
Docs: remove superfluous files (#2181)
Browse files Browse the repository at this point in the history
  • Loading branch information
lukegalbraithrussell committed Aug 1, 2024
1 parent 945e9f0 commit 51c1886
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 1,422 deletions.
9 changes: 4 additions & 5 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# slack.dev
# slack.dev/bolt-js

This website is built using [Docusaurus](https://docusaurus.io/). 'Tis cool.

Expand All @@ -13,7 +13,7 @@ docs/
├── i18n/ja-jp/ (the japanese translations)
│ ├── docusaurus-theme-classic/ (footer/navbar translations)
│ └── docusaurus-plugin-content-docs/
│ └── current/ (this folder's file names need to exactly match **/content/, but japanese content)
│ └── current/ (this folder's file names need to match **/content/)
│ ├── getting-started.md
│ └── concepts
│ └── sending-message.md
Expand Down Expand Up @@ -43,9 +43,8 @@ A cheat-sheet:

1. Make a markdown file. Add a `# Title` or use [front matter](https://docusaurus.io/docs/next/create-doc) with `title:`.
2. Save it in `content/folder/title.md` or `content/title.md`, depending on if it's in a sidebar category. The nuance is just for internal organization.
3. There needs to be 1:1 docs content for the sidebar. Copy the folder/file and put it in the Japanese docs: `i18n/ja/docusaurus-plugin-content-docs/current/*`. Just leave it in English if you don't speak Japanese.
4. Add the doc's path to the sidebar within `docusaurus.config.js`. Where ever makes most sense for you.
5. Test the changes ↓
3. Add the doc's path to the sidebar within `docusaurus.config.js`. Where ever makes most sense for you.
4. Test the changes ↓

---

Expand Down
1,289 changes: 0 additions & 1,289 deletions docs/content/Changelog.md

This file was deleted.

13 changes: 6 additions & 7 deletions docs/i18n/ja-jp/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
# slack.dev
# Bolt for JavaScript Japanese documentation

This README describes how the Japanese documentation is created. Please read the [/docs README](./docs/README) for information on _all_ the documentation.

[Docusaurus](https://docusaurus.io) supports using different languages. Each language is a different version of the same site. Therefore, the Japanese documentation and English documentation must have the exact same pages.
[Docusaurus](https://docusaurus.io) supports using different languages. Each language is a different version of the same site. The English site is the default. The English page will be viewable if the page is not translated into Japanese.

If you add a page to the English documentation, then you must add the page to the Japanese documentation too. If you don't speak Japanese, copy the English documentation to the Japanese page.

There will be English pages on the Japanese site if the pages are not translated yet. Japanese readers will not miss any content, but they may be confused seeing English and Japanese mixed together. Please give us your thoughts on this setup.
There will be English pages on the Japanese site of the pages are not translated yet. Japanese readers will not miss any content, but they may be confused seeing English and Japanese mixed together. Please give us your thoughts on this setup.

Because of this, the sidebar does not need to be updated for the Japanese documentation. It's always the same as the English documentation!

Expand Down Expand Up @@ -47,6 +45,7 @@ The Japanese documentation is in `i18n/ja-jp/`. The folder contains `docusaurus-
```
docs/
├── content/ (English pages)
│ ├── example-page.md
│ ├── getting-started.md
│ └── concepts
│ └── sending-message.md
Expand All @@ -58,9 +57,9 @@ docs/
│ └── sending-message.md
```

The Japanese page files in `i18n/ja-jp/docusaurus-plugin-content-docs/current/` must be the same as the English page files in `docs/content/`. Please keep the file names in English (example: `sending-message.md`)
If the file is not in `i18n/ja-jp/docusaurus-plugin-content-docs/current/`, then the English file will be used. In the example above, `example-page.md` is not in `i18n/ja-jp/docusaurus-plugin-content-docs/current/`. Therefore, the English version of `example-page.md` will appear on the Japanese site.

Each page is a markdown file. If the page is not translated, it will be in English. Simply remove the English words and write Japanese to replace the page.
The Japanese page file formats in `i18n/ja-jp/docusaurus-plugin-content-docs/current/` must be the same as the English page files in `docs/content/`. Please keep the file names in English (example: `sending-message.md`).

Please provide a title in Japanese. It will show up in the sidebar. There are two options:

Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

21 changes: 0 additions & 21 deletions docs/i18n/ja-jp/docusaurus-plugin-content-docs/current/index.md

This file was deleted.

6 changes: 5 additions & 1 deletion docs/sidebars.js
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,11 @@ const sidebars = {
{type: 'html', value: '<hr>'},
'reference',
{type: 'html', value: '<hr>'},
'Changelog',
{
type: 'link',
label: 'Release notes',
href: 'https://github.com/slackapi/bolt-python/releases',
},
{
type: 'link',
label: 'Code on GitHub',
Expand Down

0 comments on commit 51c1886

Please sign in to comment.