Skip to content

Commit

Permalink
fix: dynamic editUrl path for documentation subfolder structure (#247)
Browse files Browse the repository at this point in the history
* Fix dynamic `editUrl` path for documentation subfolder structure

* Update sidebar path

* Update sidebar path

* Update package-lock.json
  • Loading branch information
Codexnever authored Oct 10, 2024
1 parent fd93663 commit 8916859
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,11 @@ const config = {
'classic',
/** @type {import('@docusaurus/preset-classic').Options} */
({
docs: {
docs: {
sidebarPath: './sidebars.js',
// Please change this to your repo.
editUrl:
'https://github.com/open-sauced/intro',
// Dynamic editUrl construction
editUrl: ({ versionDocsDirPath, docPath }) =>
`https://github.com/open-sauced/intro/edit/main/${versionDocsDirPath}/${docPath}`,
routeBasePath: '/',
},
theme: {
Expand Down

0 comments on commit 8916859

Please sign in to comment.