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

Show a preview of the component posted by users so others can see how it looks. #26

Closed
Parth18Shah opened this issue May 29, 2024 · 7 comments
Assignees
Labels

Comments

@Parth18Shah
Copy link
Contributor

Parth18Shah commented May 29, 2024

This will help them decide if they want to use it or not.
Please assign me this enhancement under gssoc'24.

Copy link

Thank you for creating this issue! 🎉 We'll look into it as soon as possible. In the meantime, please make sure to provide all the necessary details and context. If you have any questions or additional information, feel free to add them here. Your contributions are highly appreciated! 😊

You can also check our CONTRIBUTING.md for guidelines on contributing to this project.

@Parth18Shah Parth18Shah changed the title Show a preview of the component posted by users so others can see how it looks. This will help them decide if they want to use it or not. Please assign me this enchancement under gssoc'24. Show a preview of the componentposted by users so others can see how it looks. May 29, 2024
@Parth18Shah Parth18Shah changed the title Show a preview of the componentposted by users so others can see how it looks. Show a preview of the component posted by users so others can see how it looks. May 29, 2024
@VaibhavArora314
Copy link
Owner

how are you planning to implement this?

@Parth18Shah
Copy link
Contributor Author

Initially, I plan to take an easier approach, dynamically inject the CSS code, and render it (perhaps by using dangerouslySetInnerHTML, which obviously will include me cleaning the code to reduce the security risk this can pose). Subsequently, I plan to research more methods to improve this feature to provide a more secure and faster way to render the previews. Apologies if you were expecting a more advanced approach. This is the only approach I am aware of now, and I will be open to any suggestions from your end. It will be a crucial feature to add to your application.

@Parth18Shah
Copy link
Contributor Author

On basic parsing of the net, I found react-jsx-parser and html-react-parser, which could be explored further by me after implementing the basic approach mentioned by me above. Please allow me to try both approaches (i.e., the first one being the easier one to introduce this feature and the second one improving it). let me know if I can create two PRs for it(if both work).

@VaibhavArora314
Copy link
Owner

Sure go ahead. As for the second part, you can later raise another issue for enhancing the preview feature after implementing this.

@Parth18Shah
Copy link
Contributor Author

Sure, that works. Thanks!

VaibhavArora314 added a commit that referenced this issue Jun 2, 2024
Copy link

github-actions bot commented Jun 2, 2024

Hello @Parth18Shah! Your issue #26 has been closed. Thank you for your contribution!

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

No branches or pull requests

2 participants