YousefED / SyncedStore

SyncedStore CRDT is an easy-to-use library for building live, collaborative applications that sync automatically.
https://syncedstore.org
MIT License
1.71k stars 51 forks source link

Docs: Svelte integration #48

Closed SkaterDad closed 2 years ago

SkaterDad commented 2 years ago

Here's a basic Svelte docs page with static code blocks.

As mentioned in the previous PR, I've had issues with Sandpack and Svelte.

I was able to set up a Svelte REPL that mostly works. For some reason it stops rendering the list of TODOs if you remove the <pre> block that is subscribed to the entire store. What's neat is that you can collaborate on the TODOs using the React and Vue examples from your other docs pages.

https://svelte.dev/repl/a3eb6fab2c8a47019ca7dc12701f6b7b?version=3.46.3

I updated my previous Codesanbox example to use the updated @syncedstore/svelte npm package. Work great, even if you remove the <pre> block.
https://codesandbox.io/s/reverent-glitter-lb1g7?file=/App.svelte

Example (and buggy online playgrounds) aside, I hope to integrate this library into a Svelte app I've been building.

I may try to write up a tutorial as I learn more.

coveralls commented 2 years ago

Pull Request Test Coverage Report for Build 1766896525

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details


Totals Coverage Status
Change from base Build 1765489788: 0.0%
Covered Lines: 497
Relevant Lines: 584

💛 - Coveralls
YousefED commented 2 years ago

Merged as part of #51. Thanks @SkaterDad !

I'll deploy a new version of the docs and website. A blog post would be really cool. Any other ideas on where to highlight this to the Svelte community? (I'm not a really active svelte user)

PS: are you on the discord channel (see readme)? Then I'll mention you in the announcement :)