-
Notifications
You must be signed in to change notification settings - Fork 1.3k
docs: Fix sandboxes, localStorage, and search cards #9135
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
| return [value, store.setValue]; | ||
| } | ||
|
|
||
| class Store { |
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.
just in case something goes unexpectedly wrong, should we have an easy way to clear out all of our values?
do we have any ways of confirming/enforcing that we don't have conflicting keys across pages and examples?
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.
the keys are intended to be global. When you change your packageManager, the whole site remembers across all pages.
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.
yeah, but if some combination of settings from across the site ends up accidentally conflicting in an unforseen way, it could cause a page to crash making it difficult to recover.
Or maybe someone just wants to start over with the defaults.
Some will guess or know you can go clear local storage, but I still think it could be useful to have a clear button somewhere
|
Build successful! 🎉 |
# Conflicts: # packages/dev/s2-docs/src/SearchMenu.tsx
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.
Still going through the changes in here, but I was testing the codesandbox creation and it looks like it is copying the "Expand code"/"Collapse code" that is present depending on the expand/collapse state the code is in when you trigger sandbox creation? Testing via https://reactspectrum.blob.core.windows.net/reactspectrum/ee77fca2f1f13b1aae3b60f36cf7fd2aa5011a69/s2-docs/react-aria/Autocomplete.html
Additionally, even after getting rid of that, the example needs a export default but then will run properly after adding that
|
Build successful! 🎉 |
|
@LFDanLu looks like I refactored it at the last minute and got the wrong DOM element. 🤦 |
|
Build successful! 🎉 |
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.
|
I thought it looked weird that the search field didn't line up with the tags/cards... |
|
Build successful! 🎉 |
|
@devongovett Unrelated to the changes here, but wanted to note that it may make sense to add a
|


useSyncExternalStoreso that there is no flicker when navigating