Closed lukegalbraithrussell closed 1 month ago
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 74.98%. Comparing base (
9db47c3
) to head (a94b9a7
).
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@seratch Nice catch! For some reason Java highlighting isn't enabled by default in Docusaurus. I've added the syntax highlighting for both Java and Groovy
@lukegalbraithrussell Thanks for quickly resolving it!
With the latest revision, the only remaining issue I found is /image/* file access error. For example, img/bolt-middleware.png
access from http://localhost:3000/java-slack-sdk/guides/bolt-basics
returns not found HTML page instead of the png file. Can I ask you to identify the cause?
@seratch The pictures are now working. Those shortened /img/path
file paths (instead of /docs/static/img/path
) only work in markdown it seems. I switched it to markdown!
Summary
This PR adds a Docusaurus site. Tested that it builds properly. This is all done in the same way as the other sites site.
https://github.com/user-attachments/assets/f6319792-48d9-4d5e-a6ad-b878f5f570ea
14,569 of those line changes are from
package-lock.json
. So it's really a +1900 changeIf you've looked at the previous PRs, it's all pretty similar, with the exception of
docs/version-config.yml
and its use in.workflows/doc-deploy
.You'll see placeholders in markdown files for version values. For example:
sdkLatestVersion
. The github workflow replaces these placeholders with the values set indocs/version-config.yml
. ThesdkLatestVersion
value is set viascripts/set_version.sh
but the other values are changed directly in the file. When a value inversion-config.yml
is changed, the site is rebuilt automatically due to the github workflow looking for changes to/docs
. I tested this all out on my personal deployed docusaurus test site.Anyway, there are about only a few files in this PR that matter for review.
Maintenance files:
Site config files:
The 404 page has two files, for Docusaurus ~ reasons ~
Folder and file organization
This shares the same structure as the other sites. At large:
Docs pages: slugs and links
The organization of pages is purposefully kept as similar to the current layout of pages so developers don't get jarred from both a site change and page changes. Slugs are all named matching that previous organization. URLs stay the same for the English site.
The Japanese site unfortunately has to have slightly different slugs - they were at
/guides/ja/page
and docusaurus does/ja/guides/page
. At that point, I changed it to/ja-jp/guides/pages
to match the other sites. I've added redirects, but they may need to toggle the language once redirected.All
.md
files were renamed to match the title and the slug. Everything now matches up.All markdown reference links were also updated to be up-to-date and working. If it's a link on the site, it now works. They should all be the most basic of markdown now.
Editing and managing the site
The README contains a basic docs editing guide. You don't need to worry about the site unless you're touching something inside the
/docs
folder.There is a new action workflow: it does a test build on docs PRs and deploys the site on merges to main. It does so also on every release so the generated reference docs stay up-to-date
Next steps
This wouldn't be a DevRel project without some fast follows. This is what I plan on doing after all the sites are live:
custom.css
if the main site'scustom.css
is changed.Testing
You can run the site locally:
npm install
npm run start
You can build and serve on your computer to swap between english and japanese:
npm run build
npm run serve
Click around! have fun!
Category
Just docs
Requirements
Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you agree to those rules.