-
Notifications
You must be signed in to change notification settings - Fork 9
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
use autosave rhs for spec #2143
Conversation
The Playground panel also needs this mechanism. Could we add auto-save to the CodeSubmode component so it can be used by both the Playground panel and the Spec Preview? Or would it be better to have auto-save options in the card resource itself? |
Ok I see. I feel pushing everything up to code-submode will make it cluttered as others have complained about this before. Presumably, we want some sort of abstraction to make the auto-save reusable. Do you think its a good idea to use another resource to encapsulate |
I think it's a good idea. What do you think? @lukemelia @habdelra |
TBH, this sounds like a feature of the store. like when you use Also a refactor like this would eliminate one of the TODO's noted in the |
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 great!
packages/host/app/components/operator-mode/code-submode/spec-preview.gts
Outdated
Show resolved
Hide resolved
Thanks @habdelra for the input. I have excluded this refactor and @FadhlanR will take a first pass at it in his playground panel auto-save pr |
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.
Not the smoothest editing experience (sometimes autosave happens while still typing, and sometimes the spec panel disappears and comes back) but it works.
I'll see if I can refine this after integrating with store auto-save fadhlan is working on |
https://www.loom.com/share/eec55ba818994f39b69791bf22c46ae2?sid=b9ff9e70-7259-4507-a059-8d273b99c43c