Skip to content
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

Improve Previews #8

Open
poef opened this issue Jun 12, 2023 · 1 comment
Open

Improve Previews #8

poef opened this issue Jun 12, 2023 · 1 comment

Comments

@poef
Copy link
Member

poef commented Jun 12, 2023

Previews aren't always completely up to date, you need to save a component to see all CSS changes reflected. This should not be necessary. In addition, performance of previews gets worse the longer you use SimplyCode.

  • Create an improved preview builder, which uses all uptodate code
  • Only build previews if they are viewable (in a viewable area in the browser)
  • Allow a preview to be opened in a seperate tab/window, keep live updates going
@ylebre
Copy link
Contributor

ylebre commented Feb 20, 2024

The performance issue has already been addressed previously, this should no longer be an issue.

This PR: #23 adds routes to each preview so that they can be viewed separately.

Live updates to the previews are a bit more complicated, I think these warrant a phased approach:

  1. include changes in the CSS from the current component.
  2. sync changes from anywhere, including from different pages. This is needed to be able to update previews in separate windows, as well as syncing changes from other components (like a base style change). We can build on localStorage for this.
  3. allow the sharing of the 'state' using something like hyperhyperspace, so we can even live update across devices.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants