-
Notifications
You must be signed in to change notification settings - Fork 38
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
[Rewrite] General Improvements #20
base: master
Are you sure you want to change the base?
Conversation
[Fix] gitignore in repo root
Hello @ash0x0, The OpenVidu team is not expert in React. We welcome your contributions to the OpenVidu-Call-React application. |
[Refactor] Reorganize package hierarchy
[Refactor] Add linting and styler [Refactor] Merge package.json from 'library' and 'call-react' [Refactor] Update build scripts
Great. Outstanding items are:
Right now, this remains in draft state. It currently needs someone to review and decide if the decisions made here are acceptable. Also to test the functionality and make sure everything required is there. |
Hi, I am not 100% sure, but I think the |
Well, with these changes, both of these usecases are supported. We would just need to update the demo page to remove The reason I made the change is that it was weird and difficult to work with the old structure, also the tooling wasn't working well and there's really no technical reason why we should separate the two. The solution I have has a few build steps to manipulate some files to build the library but usage-wise, this should work exactly the same as the old structure, the only noticeable changes are the build script names. If this structure would be an issue for other parts of the project, we can introduce a link or a copy script to add back the old path while having the code reside at the root, similar to how |
[lint] linting for src directory
@pabloFuente @micaelgallego Is the code related to screen sharing extension still needed? given that the extension is deprecated I'm wondering why it's here. Can it be removed? |
Yes, you can remove code related with screen share extension as it is no longer needed. |
[Fix] Update prettier configuration
[Feature] Render props to chat and toolbar [lint] Config update [lint] Source linting and style fixes
Ok not everything is done with this yet but it's working well enough to review. Now though, I'll need some reviews on this to address anything that requires changing and merge it to move forward. I'll introduce a separate PR soon for the layout refactor based on this tree. Let me know if you'd like me to squash commits. |
Hello @ash0x0 , First of all, thank you for your contribution to OpenVidu, as you know we are not React developers and we need to the community to be up to date with all frameworks and web technologies that we support. Secondable, I have check and test your updates and looks great, however I have come across some errors. I will detail them.
We need these bug fixes to be able to merge your PR. Regards |
Thanks for the review, I'll get on these and update. On the last point, this is actually intentional and I'll PR doc updates for The current way to use the library allows for this: <OpvSession
id="opv-session"
sessionName={mySessionId}
user={myUserName}
openviduServerUrl={'https://localhost:4443'}
openviduSecret={'MY_SECRET'}
joinSession={this.handlerJoinSessionEvent}
leaveSession={this.handlerLeaveSessionEvent}
error={this.handlerErrorEvent}
/> which provides the library component with the openvidu server url and secret and leaves the token-grabbing logic to the library. This shouldn't be the case. The openvidu address and secret shouldn't be in a frontend react application at all. As the secure tutorials indicate, this logic should be in the server-side. That's why I'm removing it from the library. Now the usage should be like this: <OpvSession
id="opv-session"
sessionName={mySessionId}
user={myUserName}
token={openViduSessionToken}
joinSession={this.handlerJoinSessionEvent}
leaveSession={this.handlerLeaveSessionEvent}
error={this.handlerErrorEvent}
/> with |
I'm making a few general improvements to use this project. This is a PR to get discussion about these going and track progress.
The issues I mean to address are:
@pabloFuente if I'm not mistaken, you're the one maintaining this repo for the moment. What do you think about these changes and are they generally welcome?
I also have a question about the structure of this repo. Is there a reason this is split to the
library
andopenvidu-call-react
packages? As far as I can tell, it's all placed intolibrary
at the end of the day and published there and there doesn't seem to be any specific reason whyopenvidu-call-react
is separated. Is this for some legacy compatibility reasons?If it'd be possible, I think it'd be better to change the structure to a single package under root, it would be easier to work with and contribute to, the structure right now is a little unusual. If there's a reason for this perhaps we can add to README.