muke1908 / chat-e2ee

End-to-end encrypted disposable chat sessions, exchange sensitive information with peer safely and securely.
https://chat-e2ee-2.azurewebsites.net/
Apache License 2.0
323 stars 198 forks source link

Create a JS playground with @chat-e2ee/service package #289

Open muke1908 opened 1 year ago

muke1908 commented 1 year ago

Create a fiddle using @chat-e2ee/service package to demonstrate basic functionalities. use @chat-e2ee/service@1.0.8

https://github.com/muke1908/chat-e2ee/tree/master/service

rohan-naik07 commented 8 months ago

Hi @muke1908 .... can I take up this?

muke1908 commented 8 months ago

@rohan-naik07 Sure, go ahead.

rohan-naik07 commented 8 months ago

fiddle means online code editor right that exposes all the APIs of the sdk ...like two code editors which represent 2 users and we can create a dummy channel between them?

muke1908 commented 8 months ago

@rohan-naik07 yes, working demo of the exposed APIs on the SDK.

rohan-naik07 commented 8 months ago

So basically I will proceed with a new react app called e2ee-playground.

muke1908 commented 8 months ago

I think you can just keep it vanilla-js, react-app is unnecessary imo. You can use codesandbox for writing code. Instead of 2 editor, we can simulate 2 users using iframe - user1 is main window, user2 embedded in an iframe.

Here is an example: https://codesandbox.io/p/sandbox/gracious-pine-6jhqwt

rohan-naik07 commented 8 months ago

So its just creating two html pages in the sandbox which simulate two users and embed the second user in first user's window. the two users can send messages to each user using common channel.

muke1908 commented 8 months ago

Yes. I didn't understand what you meant by "common channel" but they both will have their own chatInstance