-
Notifications
You must be signed in to change notification settings - Fork 1.4k
docs: Update URL structure #9237
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
Build successful! 🎉 |
reidbarber
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like the index links are broken
|
Build successful! 🎉 |
# Conflicts: # packages/dev/s2-docs/pages/react-aria/GridList.mdx # packages/dev/s2-docs/pages/react-aria/Table.mdx # packages/dev/s2-docs/pages/react-aria/Tree.mdx # packages/dev/s2-docs/pages/s2/CardView.mdx # packages/dev/s2-docs/pages/s2/TableView.mdx # packages/dev/s2-docs/pages/s2/TreeView.mdx # packages/dev/s2-docs/src/Header.tsx # packages/dev/s2-docs/src/NavigationSuspense.tsx
|
Build successful! 🎉 |
|
Build successful! 🎉 |
| // eslint-disable-next-line | ||
| import {transformAsync} from '@parcel/rust/lib/index.js'; | ||
|
|
||
| export const getPages = cache(async () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This parses all MDX files so we have a complete list of pages, even when the Parcel build doesn't include all of them (building only S2 or RAC). Using an internal Parcel utility here for performance (the pages get parsed in parallel in Rust). Will have to keep this up to date with Parcel upgrades. Ideally there'd be a public utility for this.
# Conflicts: # packages/dev/s2-docs/pages/s2/index.mdx # packages/dev/s2-docs/src/Layout.tsx # packages/dev/s2-docs/src/MobileSearchMenu.tsx # packages/dev/s2-docs/src/SearchMenu.tsx
|
Build successful! 🎉 |
Removes the
.htmlextension from all docs URLs. The CDN will automatically return either HTML or Markdown depending on theAcceptheader, and the URLs also look a bit cleaner this way.Updates the build to split the URL structure into separate domains for react-aria and react-spectrum. Locally, by default, there is still only a single server so
http://localhost:1234/s2andhttp://localhost:1234/react-aria(internationalized moved under react-aria). But in the build (or optionally locally), there are two separate Parcel builds for these, and they cross-link to each other. The list of pages has their URLs normalized so we always have absolute URLs with the correct domains attached according to the environment.