web-gphoto2 icon indicating copy to clipboard operation
web-gphoto2 copied to clipboard

Add Svelte demo project

Open icheered opened this issue 2 years ago • 3 comments

icheered avatar Aug 06 '23 12:08 icheered

Nice! My main concern is that this is quite a lot of code to keep & potentially maintain in a repo that - as you noticed before - isn't actively maintained.

It looks like a full-featured app. To be fair, so was the original demo, but there the app was the point of the showcase / article.

Now that the library is published to npm, it might best to publish the Svelte app to a separate repo with its own Github Pages or other kind of deployment, and just put a link in the README here instead?

RReverser avatar Aug 07 '23 14:08 RReverser

I understand your concern, this simple demo quickly grew quite large since I wanted to show the 'right' way of using the package.

I'm thinking I should probably publish this separately, and instead put what I previously had as the 'quick example of using the package' (in the PR readme) as the svelte demo. We could have a 'Cool things made with this package' section and link it to the project?

I'll try to finish this soon but I got kind of stuck with the connect/disconnect issue mentioned in #8. I'll try to see what I can do!

icheered avatar Aug 07 '23 20:08 icheered

but I got kind of stuck with the connect/disconnect issue

Without changing the API the solution is pretty simple - just create a new Camera in the same place you do .connect(). What I said there is just that we should change the API to make it harder to misuse, but for the demo you can work with what you have right now as well.

RReverser avatar Aug 08 '23 10:08 RReverser